Cron (scheduled) version Manual

Why
Moresuitable?

Demo

Showcase

Play with
Template

SSI vs. Cron
(scheduled)

Download

Manual

FAQ

Feedback form

Rate Us!

Contact Us

Add URL

Home page

 

Moresuitable installation is extremely easy. Just follow these simple steps.

For SSI (on-the-fly) version see SSI version Manual.

  • If you are using UNIX and have the ability to set cron jobs then follow the instructions.
  • If you are using an NT server then contact your provider to see if they will allow you to automate scripts. If so they will need to set up the automation.
  1. Download the Moresuitable Cron package: Moresuitable_Cron.zip.
  2. Edit the script's file.
    • Open up the downloaded package.
    • Open up 'moresuitable_cron.pl' with NOTEPAD (or any other text editor) and change the first line to the correct path to Perl on your server.
      If you are not sure what is the path, take a look at your webhosting provider's FAQ. Probably it would be '/usr/bin/perl' or '/usr/local/bin/perl'.
    • Choose the desirable news category from the News Category List (also contained in the package). Cut-n-paste your category's URL to the line 19.
    • Set the number of news headlines you want to embed at the line 23 (must be between 1 and 20). The default is 5.
    • Put the name of your result HTML file (newspage on your website), including the full path, to the line 26.
    • Set the name of your lib dir, including full path, at the line 31. Alternatively you may put the '#' sign to the first position of the line if you sure you already have perl modules 'LWP::UserAgent' and 'HTTP::Request' installed on your webserver.
    • Set the name of your HTML template file including full path at the line 34.
  3. Edit the template file.
    • Open up 'news_cron_html.tpl' with your text editor.
    • Note a few uncommon elements:
      1. Special comment tags:
        <!-- %%Repeating_part_begin%% -->
        and
        <!-- %%Repeating_part_end%% -->
        Please don't edit these two tags. The script will look for them in you template to find the code for your news lines, which is between the tags.
      2. Special characters in the news lines code. The script will put the real data instead of the following pieces of code:
        %%Article_URL%% -- Article URL, including the unique Moreover article ID number;
        %%Headline%% -- Headline text itself;
        %%Source_URL%% -- the front page URL of the source;
        %%Source%% -- the name of the online publication the article is from;
        %%Reg_URL%% -- the URL for registration/subscription if needed;
        %%Access_status%% -- possible values: 'reg' - registration needed, 'sub' - subscription needed, blank - neither;
        %%Extraction_time%% -- the time the article was added to Moreover database.
        You may skip any field that you don't want to appear in your news.
    • Edit the template as regular HTML file. That will be one of your website's pages, containing the news. Add anything you want to it. Please don't remove the links to morover.com (which provides the newsfeeds) and moresuitable.com ( which provides the script). This is the condition of free licence.

      Actually you can just insert the following code into one of your existing pages, where you want news to appear. Than rename it to 'news_cron_html.tpl'.

  4. Upload the files to your server:
    • upload 'moresuitable_cron.pl' and 'news_cron_html.tpl' in ASCII mode, NOT binary to any directory enable to run Perl scripts on your webserver;
    • upload 'lib' dir from the package to the same dir as 'moresuitable_cron.pl'
  5. Make your crontab settings:
    • telnet to your webserver account;
    • type 'crontab -e'. The editor window should open;
    • type '0,30 * * * * /path/to/perl /path/to/the/moresuitable_cron.pl'
      Make sure to change '/path/to/perl' to your path to perl and
      '/path/to/the/moresuitable_cron.pl' -- to appropriate path.
      This should set the corn job and your moresuitable_cron.pl script should run every 30 minutes.
That's it! Everything should work properly.

Good luck!

 

Home Page || Add URL || Contact us