View Single Post
Old 11-18-2017, 06:40 AM  
just a punk
So fuckin' bored
 
just a punk's Avatar
 
Industry Role:
Join Date: Jun 2003
Posts: 32,342
Quote:
Originally Posted by bimbocams View Post
I want the keyword in the beginning followed by models name
You can use the following PHP code:

Code:
$keywords = array('my keyword', 'my keyword 2', 'my keyword 3');
$post['post_title'] = $keywords[rand(0, count($keywords) - 1)] . ' ' . $post['post_title'];
If your keywords are stored as a text file (one keyword per line), you can use it like this:

Code:
$keywords = file('http://www.mysite.com/keywordlist.txt');
$post['post_title'] = $keywords[rand(0, count($keywords) - 1)] . ' ' . $post['post_title'];
Just make sure to replace http://www.mysite.com/keywordlist.txt with the actual URL of your text file.
__________________
Obey the Cowgod
just a punk is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote