Search found 195 matches

Search found 195 matches

Re: What PHP file executes only once per visitor?

Events seems a bit complicated, don't really understand how they work.

I can make a OCmod file however, which controller file should I be putting my PHP code in to have it execute only once?

Jump to post
  • Thu Mar 28, 2024 12:53 pm
  • Replies 2
  • Views 72
What PHP file executes only once per visitor?

I need to add some PHP code to my site but it should only execute once per visitor.

What PHP file in OC3 only runs once per visit?
PS is maybe a /system/startup.php a good place to add it?

.
.

Jump to post
  • Thu Mar 28, 2024 4:54 am
  • Replies 2
  • Views 72
Re: Discount "-" negative sign missing in checkout total

ADD Creative wrote:
Sat Mar 23, 2024 5:42 pm
Try changing.

Code: Select all

'value' => (($discount / 100) * $total['total']),
To.

Code: Select all

'value' => -(($discount / 100) * $total['total']),
That actually worked ツ, thank a bunch. I was actually afraid to mess with it since I don't know much about PHP and didn't want to mess up my checkout.

Jump to post
  • Sun Mar 24, 2024 12:26 am
  • Replies 5
  • Views 215
Re: Encoded URL's don't work... And how to fix it?

The new BUY NOW button under the product was doing this. Instead of sending the customer straight to OC checkout with item already in the cart, it was just sending them to 404 error page. Uploaded via google shopping XML file. Right now since I updated my items/xml file I can't find them on google s...

Jump to post
  • Sat Mar 23, 2024 7:04 am
  • Replies 5
  • Views 225
Re: Discount "-" negative sign missing in checkout total

Extension is old, debt the developer cares much about it so many years later Fontend total field only has this in it, I don't see anything here about text. I need to add the "-" between $ and 104.33 <?php /** * */ class ModelExtensionTotalPaymentDiscount extends Controller { public functio...

Jump to post
  • Sat Mar 23, 2024 6:30 am
  • Replies 5
  • Views 215
[SOLVED] Discount "-" negative sign missing in checkout total

Hi I am testing using an extension called "Payment Discount Lite" to add a 25% OFF discount to "Cash on Delivery" payments. Issue I have is that in checkout the "Cash on Delivery" does show a 25% discount correctly but its missing a - negative sign in front of it. I was...

Jump to post
  • Sat Mar 23, 2024 4:21 am
  • Replies 5
  • Views 215
Re: Encoded URL's don't work... And how to fix it?

I don't understand the difference, sorry totally php newbie here.

The site is actually google shopping and its sending the URL like this, and that doesn't work on opencart

Code: Select all

https://demo.opencart.com/index.php%3Froute%3Dproduct%2Fproduct%26product_id%3D40

Jump to post
  • Fri Mar 22, 2024 8:42 pm
  • Replies 5
  • Views 225
Encoded URL's don't work... And how to fix it?

Hi I just realized that encoded URL's don't work, so say changing = into %3D destroys the URL. Many websites encode URLS so the backlinks from those sites are kinda useless as they don't go where they should. Went and tested it on OC.com demo site and it doesn't work there either. Is there anyway to...

Jump to post
  • Fri Mar 22, 2024 3:57 pm
  • Replies 5
  • Views 225
[SOLVED] How to add image width="" height="" to FEATURED module in OC3?

Trying to improve my website speed scores and this was one of the suggestions. When checking the sources code you can see that featured module in OC3 does not add width="" and height="" to images

Does anyone know what files need to be edited to make this possible?

Jump to post
  • Sat Mar 16, 2024 2:41 pm
  • Replies 1
  • Views 166
Re: Make a checkout URL with specific product in cart e.g. ***route=checkout/checkout/?product_id={id}

Your extension still doesn't allow you to just add this ?add&product_id=90 to any URL on your website and add that item to cart...

Jump to post
  • Fri Jan 12, 2024 1:20 pm
  • Replies 7
  • Views 1230
Re: Make a checkout URL with specific product in cart e.g. ***route=checkout/checkout/?product_id={id}

Actually, it does work. Adding item to cart works, and adding quantity works. Only adding options doesn't seem to work. Do you see any issues in the options code? I was using the wrong URL structure. URL should look like this: ADD only item to cart OK: example.com/index.php?route=extension/module/bu...

Jump to post
  • Thu Jan 11, 2024 10:33 pm
  • Replies 7
  • Views 1230
Re: Make a checkout URL with specific product in cart e.g. ***route=checkout/checkout/?product_id={id}

I have a save cart extension which puts your current cart into a URL and saves it to DB but I would have to do each product manually. More importantly it has a weird URL. I really need the URL to look something like this: example.com/?add_product_id=90 OR example.com/index.php?route=checkout/checkou...

Jump to post
  • Thu Jan 11, 2024 9:22 am
  • Replies 7
  • Views 1230
Make a checkout URL with specific product in cart e.g. ***route=checkout/checkout/?product_id={id}

Just want to be able to add any product_id to checkout in a simple link so something like this example.com/index.php?route=checkout/checkout/?product_id=10 Can this be added easy to OC 3? while ago someone help me add coupons straight to cart and it wasn't much code at all so now I can add coupons t...

Jump to post
  • Thu Jan 11, 2024 6:54 am
  • Replies 7
  • Views 1230
Re: Is there anyway possible to make Theme + SASS refresh via CRON?

Well SASS refresh is really want Im after. I have NitroPack on my site and a countdown timer for someone, and because of the NitroPack the counter gets stuck sometimes at zero. Refreshing the SASS fixes it. I can refresh NitroPack caches but it has to be done manually and I can't figure out how to d...

Jump to post
  • Sat Nov 25, 2023 2:49 am
  • Replies 2
  • Views 276
Is there anyway possible to make Theme + SASS refresh via CRON?

I already made a php file to delete site cache daily and I execute it via my CRON job.

Wondering if there was any way to make the There and SASS refresh using a CRON job?

.

Jump to post
  • Sat Nov 25, 2023 1:15 am
  • Replies 2
  • Views 276
Re: Extension shows DISABLED but its actually ENABLED and works..?

So showing disabled isn't really anything to worry about I take it

Jump to post
  • Sat Nov 25, 2023 1:12 am
  • Replies 5
  • Views 341
Extension shows DISABLED but its actually ENABLED and works..?

Hey guys I've seen this happen in a few extensions I've tried over the years where you install an extension and you enabled it, the extension becomes enabled and works, but it still show DISABLED under admin-->modules Can anyone tell me what file controls if this says enabled or disable so that I ca...

Jump to post
  • Fri Nov 24, 2023 10:34 pm
  • Replies 5
  • Views 341
Re: Guest checkout and register checkout not sharing filled out information

I wish I knew how to do it, anyone good a javascript willing to take a shot?

Jump to post
  • Thu Nov 23, 2023 6:05 am
  • Replies 5
  • Views 440

Search found 195 matches