Is it possible to set a discount of the product via cron on Opencart 2.x?

0 like 0 dislike
6 views
Welcome!

How can I set a discount product via cron (or just execute the php file) to Opencart 2?
The essence is this: on the home page are randomly displayed multiple items with random discount. The next day will be displayed in other goods ("last night" discount will be removed). And so every day.

Any ideas on implementing this? How would you do it? How you would implement differently? Causing the idea.
Thank you!
by | 6 views

1 Answer

0 like 0 dislike
If it is cron and php, they don't really need Opencart as such. Just according to schedule runs the php script Kron, he climbs into the database and changes kaki some data. All. And this whole scheme is absolutely not important it's Opencart or something else. The script only needs to know that there is a base (its name), you need a password and user to access it, the table, in it the row number and column name in which it is necessary to change the digit.
by

Related questions

0 like 0 dislike
1 answer
asked May 22, 2019 by kamisarlapsha
0 like 0 dislike
1 answer
0 like 0 dislike
1 answer
asked May 4, 2019 by serg_small_developer
0 like 0 dislike
2 answers
asked Jun 7, 2019 by P1RATE
110,608 questions
257,186 answers
0 comments
1,054 users