May 4, 2011

Replacing post title and body words.... | CyberSEO Pro | Support Forum

Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Related Related Topics sp_TopicIcon
Replacing post title and body words....
Topic Rating: 0 Topic Rating: 0 Topic Rating: 0 Topic Rating: 0 Topic Rating: 0 Topic Rating: 0 (0 votes) 
August 20, 2011
5:27 pm
Avatar
otherwhirl
Guest
Guests

Hi,
I've got a few questions. I have attached a few images and have links to share in an attempt to try and illustrate (and simplify) what it is that i need to do.

Using Login to see this link
Login to see this link

1) I want to add my personal text and URLS inside each post how is this done?
You will see i need to also remove the tumblr blog names from the title post fields. i.e.,"curveappeal:" as well as in the body of some post.

Would that be done in the Global Synonym Table? or the Global Modifications Tool field like so: '|curveappeal:|www.yadayadayada.com'

2) There are literally dozens and dozens of tumblr feeds content is pulled from. Will i have to literally copy and paste each new one into Global Synonym Table, or is there a way to have it remove all blog titles ending with ":" ?  i.e.,  ' twiggymaster666:' , 'bigthickfathuge' , 'lovethechub' , 'deathfatties'  , etc.

3) In the case of a number of posts  which read only "photo" in the title field I will want to replace it with my own unique title. In fact, i am wondering how can I take a generic title like ' YadaYadaYada post 19 '   , ' YadaYadaYada post 20 '      '' YadaYadaYada post 21 '  ….  etc.    

Thanks!

August 20, 2011
5:56 pm
Avatar
CyberSEO
Admin
Forum Posts: 3913
Member Since:
July 2, 2009
sp_UserOfflineSmall Offline

It seems that these tasks can't be done w/o some coding. Put the following code into your "PHP Code <?php .. ?>" box on the feed options page:

Login to see the code

First line contains the list of words you want to use as replacements for "Photo" in the post titles. You have to replace it it your own words, e.g.:

$wordlist = array ('Picture', 'Cool Image', 'Nice Photo', 'Here is My Pic');

You can have there as many words or phrases as you want.

August 20, 2011
6:11 pm
Avatar
otherwhirl
Guest
Guests

Excellent! i'll give it a try.

So will this same code apply to removing content in the body? i.e.,   $wordlist = array ('word1', 'word2', 'word3' ); $post ['post_body'] = str_replace ( 'Photo', $wordlist [rand ( 0, count ( $wordlist ) - 1 )], $post ['post_body'] ); $post ['post_body'] = preg_replace ( '/^[a-z,0-9]+: /', '', $post ['post_body']

 

What about questions #2 & 3:

2) There are literally dozens and dozens of tumblr feeds content is pulled from. Will i have to literally copy and paste each new one into "PHP Code <?php .. ?>" box on the feed options page:, or is there a way to have it remove all blog titles ending with ":" ?  i.e.,  ' twiggymaster666:' , 'bigthickfathuge' , 'lovethechub' , 'deathfatties'  , etc.

3) In the case of a number of posts  which read only "photo" in the title field I will want to replace it with my own unique title. In fact, i am wondering how can I take a generic title that will generate  a numerical sequence like ' YadaYadaYada post 19 '   , ' YadaYadaYada post 20 '      '' YadaYadaYada post 21 '  after each new post?

 

admin said:

Login to see the quote

August 20, 2011
6:49 pm
Avatar
CyberSEO
Admin
Forum Posts: 3913
Member Since:
July 2, 2009
sp_UserOfflineSmall Offline

1) No this code will work for the titles only. If you need to replace some word (say "Photo") in both title and body, you should use the global synonym table to set a simple rewrite rule, e.g.:

>Photo|Picture|Cool Image|Nice Photo|Here is My Pic

2) Yes, you need to put that PHP code into the "PHP Code <?php .. ?>" field on the settings page for every feed you syndicate. Also set it by default for every new feed using the "Alter default settings button". The flowing code will automatically remove the all the "blah-blah-blah: " from the post tittles:

Login to see the code

3) If you want to have a numerical sequence for the titles instead of "Photo" (e.g. "YadaYadaYada post 1", "YadaYadaYada post 2"), you need a bit different PHP code. Here it is:

Login to see the code

This code will replace all words 'Photo' to 'YadaYadaYada post NN' and remove all 'blah-blah-blah: ' from the post titles.

If you want to replace some specific word in post body, use the rewriting rules, as explained in (1).

August 20, 2011
7:13 pm
Avatar
otherwhirl
Guest
Guests

Thanks for the quick response Smile

 

Regarding the post body rewrites it appears i'm going to have to do what I hoped to avoid, which is having to enter specific words. If you have a look at the website link that PM'd you will see there are many posts coming from several feeds.Most will have text like so included in the body:

'chaoswriter:' , 'gobigger:' , 'Login to see this link-bunnies:' , ' ilikeprettyclothes:', etc.  This is because some feeds are actually reblogged by other bloggers. With that said, I will not always know what the name ending with a ":" (colon) will be, as many will be new blog names. 

 

So my question is , is it possible to remove ALL words ending with a ":" (colon)? This way i will not have to copy and past each current and future blog name which enters into my posts. I guess similar to your response to question #2 "Also set it by default for every new feed using the "Alter default settings button". The flowing code will automatically remove the all the "blah-blah-blah: " from the post tittles:"

 

It appears the global synonym table will only allow me to replace words that I specifically enter?

 

admin said:

Login to see the quote

August 20, 2011
8:14 pm
Avatar
CyberSEO
Admin
Forum Posts: 3913
Member Since:
July 2, 2009
sp_UserOfflineSmall Offline

Now I finally got you :) Here is the code which does the trick:

Login to see the code

It will remove all "blah-bla-blah:" from both post titles and bodies.

August 20, 2011
9:57 pm
Avatar
otherwhirl
Guest
Guests

Wow!

I can't wait to try this. I'll forward you a link when its done and give an awesome review on BHW

Thanks again.

admin said:

Login to see the quote

Forum Timezone: Europe/Amsterdam

Most Users Ever Online: 541

Currently Online:
21 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

ninja321: 84

s.baryshev.aoasp: 68

Freedom: 61

Pandermos: 54

MediFormatica: 49

B8europe: 48

Member Stats:

Guest Posters: 337

Members: 2817

Moderators: 0

Admins: 1

Forum Stats:

Groups: 1

Forums: 5

Topics: 1627

Posts: 8280

Newest Members:

igor.buzaev, jeremyboucher, lthompson2709, MAC, duty3canada, backlinkmorocco

Administrators: CyberSEO: 3913