D
D
daygoodyes2021-03-22 11:20:37
PHP
daygoodyes, 2021-03-22 11:20:37

How to run PHP file in ispManager?

There is a site selling auto glass, there is a script UpdatePriceController.php that allows you to automatically update the price from the price.csv file, a site on a host with isp manager, I can’t figure out how to start all this so that everything is automatically updated. Help please, preferably in simple language, I'm not a programmer ..... but an amateur.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
N
Nord Dev, 2021-03-22
@Nordic_Alf

Well, the simplest solution, just go to the file manager or ftp there with the files / folders of the site, drop this file into a folder called public
, type your site.com/UpdatePriceController.php or your site.com/public/UpdatePriceController.php into the browser.
Perhaps there you need to look at what path is registered to price.csv, so that your script works the file, see where you need to put it in the code.

S
Sanes, 2021-03-22
@Sanes

On behalf of the user:

  • Tools -> Shell client
  • Main -> Scheduler
  • SSH

V
Viktor Taran, 2021-03-22
@shambler81

do not forget that the types of PHP representation in the console may differ from what is on the site
PHP variables and actually even the PHP version
, so it's best to run like this
wget -q --spider http://www.example.com/cronit.php
or

wget -O /dev/null http://www.example.com/cronit.php

well, or through curl.
/usr/bin/curl -s http://yourserver.com/controller >> /path/to/file.log

so you will 100% run what you need with those environment variables that are on the site itself.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question