*

oneloveb

  • ****
  • 112 posts
schema Setting
« on: September 29, 2021, 11:27:19 AM »
Hi

Please where do I locate the schema folder to change the BRAND name from OSLASS to the Items name I HAVE CHECKed items.php is not There?

"@context": "https://schema.org/",
  "@type": "Product",
  "name": "Samsung Qled Smart  - Smart TVs - ,
  "image": "https://mysite.com/oc-content/uploads/3/171184.jpg",
  "description": "55 Samsung Qled Smart
  "brand": "OSCLASS",


Thanks




Marked as best answer by oneloveb on September 29, 2021, 01:49:24 PM
*

MB Themes

Re: schema Setting
« Reply #1 on: September 29, 2021, 01:22:27 PM »
@oneloveb
I would guess it is in oc-includes/osclass/functions.php or structured-data.php
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

oneloveb

  • ****
  • 112 posts
Re: schema Setting
« Reply #2 on: September 29, 2021, 01:49:54 PM »
Thanks I got it in structured-data.php

*

mocody

  • ****
  • 139 posts
  • Only Marketing matters
Re: schema Setting
« Reply #3 on: October 03, 2021, 10:19:27 AM »
@oneloveb

Hallo, sorry to bother, can you share the solution with me i tried to do it several times but did succeeded.
thanks

*

pipetko

  • ****
  • 123 posts
Re: schema Setting
« Reply #4 on: October 03, 2021, 03:15:41 PM »
Also need solution for this :)

*

oneloveb

  • ****
  • 112 posts
Re: schema Setting
« Reply #5 on: October 05, 2021, 12:28:42 PM »
Here is it

<script type="application/ld+json">
{
  "@context": "https://schema.org/",
  "@type": "Product",
  "name": "<?php echo osc_esc_html(osc_structured_data_title()); ?>",
  <?php if($image_url <> '') { ?>"image": "<?php echo osc_esc_html($image_url); ?>",<?php echo PHP_EOL; } ?>
  "description": "<?php echo osc_esc_html(osc_highlight(osc_structured_data_description(), 200)); ?>",
  "mpn": "<?php echo osc_item_user_id();?>",
  "sku": "<?php echo osc_item_id(); ?>",
  "brand": "<?php echo osc_esc_html(osc_item_title()); ?>",
  <?php if(1==2) { ?>"sku": "OSC-<?php echo osc_item_id(); ?>",<?php echo PHP_EOL; } ?>
  "offers": {
    "@type": "Offer",
    "itemOffered": "<?php echo osc_esc_html(osc_item_title()); ?>",
    "url": "<?php echo osc_esc_html($url); ?>",
    <?php if(osc_item_price() > 0) { ?>"priceCurrency": "<?php echo osc_esc_html(osc_item_currency()); ?>",<?php echo PHP_EOL; } ?>
    "price": "<?php echo osc_esc_html(osc_item_price() > 0 ? osc_item_price() : 0); ?>",
    "priceValidUntil": "<?php echo date('Y-m-d', strtotime(osc_item_field('dt_pub_date') . ' + 365 days')); ?>",
    "availability": "https://schema.org/InStock"
  },
  "aggregateRating": {
    "@type": "AggregateRating",
    "ratingValue": "<?php echo round(osc_count_item_comments_rating(), 1); ?>",
    "bestRating": "5",
    "worstRating": "0",
    "ratingCount": "<?php echo (osc_count_item_comments() > 0 ? osc_count_item_comments() : 1); ?>",
    "reviewCount": "<?php echo (osc_count_item_comments() > 0 ? osc_count_item_comments() : 1); ?>"
  }
  <?php osc_run_hook('structured_data_footer'); ?>
}
</script>
    <?php } else { ?>
<script type="application/ld+json">
{
  "@context": "http://schema.org/",
  "@type": "Organization",
  <?php if($image_url <> '') { ?>"logo": "<?php echo osc_esc_html($image_url); ?>",<?php echo PHP_EOL; } ?>
  "name": "<?php echo osc_esc_html(osc_structured_data_title()); ?>",
  "url": "<?php echo osc_esc_html($url); ?>"
  <?php osc_run_hook('structured_data_footer'); ?>
}
</script>

*

MB Themes

Re: schema Setting
« Reply #6 on: October 06, 2021, 03:59:31 PM »
@oneloveb
 :P :P
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

pipetko

  • ****
  • 123 posts
Re: schema Setting
« Reply #7 on: May 20, 2024, 12:48:32 AM »
Trying to fix new schema issues... But It is not here I remember, cant find where to add the schema... Is it the partially code that is in item.php ?! or somewhereelse ?!

*

MB Themes

Re: schema Setting
« Reply #8 on: May 21, 2024, 06:59:13 AM »
Osclass generates most of structured data in core (structured_data.php)
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots