submit-sitemap-to-search-engines
This shell script will submit your sitemap files to google and bing search engines on a regular basis simply edit the urls you wish to submit and setup a cronjob to submit daily or weekly as required. For more information visit clusterednetworks.com
Usage:
-
Pull up a terminal or SSH into the target server.
-
Logon as root
sudo -i
- Download the script.
wget https://raw.githubusercontent.com/clusterednetworks/submit_sitemap_to_search_engines.sh
-
Edit the url to your sitemap you wish to submit to google to match your environment.
wget -O- https://www.google.com/webmasters/tools/ping?sitemap=https://www.clusterednetworks.com/sitemap.xml
-
BING requires you to encode the url you submit to them using a URL encoding tool (see https://meyerweb.com/eric/tools/dencoder/ ) you will have to use the encoder to obtain the proper URL you submit to BING. In my case it was as follows
wget -O- https://www.bing.com/ping?sitemap=https%3A%2F%2Fwww.clusterednetworks.com%2Fsitemap.xml
-
Save the file
-
Make the script executable
chmod +x submit_sitemap_to_search_engines.sh
- Run the script.
./submit_sitemap_to_search_engines.sh
- Setup a cronjob to run the script daily/weekly if you choose.
1 1 * * * /etc/submit_sitemap_to_search_engines.sh >/dev/null 2>&1
Clustered Networks
Located in Edmonton, AB Canada, Clustered Networks was Incorporated in 2001 and has offered Network / Internet and IT Consulting services for over 20 years. We offer personalized service! Call Us Today! - Click Here for our Contact Info