Jump to content
UBot Underground

[COMPLETED] Bot for changing WP footer info.


Recommended Posts

Built by: LoWrIdErTJ - BotGuru

 

I need a bot that I can give a list of WordPress sites, username/password, and some code.

 

Right now I have statcounter code in the footer, I want to pull the code out and put piwik code in.

 

The Statcounter code starts and ends with:

<!-- Start of StatCounter Code for Default Guide -->

<!-- End of StatCounter Code for Default Guide -->

 

So those two lines and all the code in between will need to be removed and the piwik code put in.

 

Thanks,

 

Richard

Link to post
Share on other sites

I don't have the files on my pc so it would have to be in the WP editor. So it would have to log into the wp site, navigate to the footer, find the code and change it.

 

Unless you know of a better way, not sure if you can hit the DB directly and do it.

 

Richard

Link to post
Share on other sites

well what i have it 300+ wordpress sites that need to be changed. It would be easiest for me, if the script can log into WP, navigate to the footer and change the code. If it can't then I'll need two bots, one to go through FTP and pull down all the footer.php pages and one to update them.

 

Richard

Link to post
Share on other sites

WP has a built in editor, so if the bot can log into wp-admin, click on Apperance, Click on Editor, click on Footer, then change the code in the footer, then click update and logout, then go to the next site and repeat.

 

Richard

Link to post
Share on other sites

if you can alter the code in wordpress then it can all be done in 1 ubot bot.

 

meaning add list of sites comma delimited with

url,user,pass

 

then it loops through all of them.


  •  
  • logs in
  • navigates to the theme editor for the footer
  • looks for the code in there now, and replaces with what you want to replace it with, saves
  • then goes to the next site and repeats the process

Link to post
Share on other sites

Will it need to replace all of the code in the whole footer.php or can if find the tracking code that needs to be replaced and replace it?

 

Richard

Link to post
Share on other sites

it would replace the tracking code alone.

 

The bot would scrape the entire footer text to a variable, look for the code area with its defined tags, then replace only the defined area with the new code you want to place there,

 

then place that text back into the editor, and save it.

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...