![]() |
![]() |
![]() |
||||
Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. |
![]() ![]() |
|
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. |
|
Thread Tools |
![]() |
#1 |
Confirmed User
Industry Role:
Join Date: Nov 2009
Location: Heaven
Posts: 4,306
|
anyone good at regex ? help needed.
i have word press site,
it has links in each post in following pattern. http://jump2link.net/watch/getdownloadmanager.php?movie=Sculpture%20(2009)%20 &authid=1321 http://jump2link.net/watch/getdownloadmanager.php?movie=Dreams%20and%20Shadow s%20(2009)%20&authid=1321 so i want to replace all these links using "search regex" plugin. i neeed help in generating regex pattern so that all links will get searched by this plugin and i can replace them. thanks for your time. |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#2 |
Confirmed User
Industry Role:
Join Date: Nov 2009
Location: Heaven
Posts: 4,306
|
as u can see the
http://jump2link.net/watch/getdownloadmanager.php?movie= this part is constant in each url and later on the movie name which is random in each post. |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#3 |
Too lazy to set a custom title
Join Date: Oct 2001
Location: Spartaaaaaaaaa
Posts: 14,136
|
if I have to take a (very) wild guess here, you should be able to do that in MySQL without having to mess with regex at all
there should be a query that finds "http://jump2link.net/watch/getdownloadmanager.php?movie=" in your links and then you can replace them with other entries????? or a few lines of PHP??? |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#4 | |
Confirmed User
Industry Role:
Join Date: Nov 2009
Location: Heaven
Posts: 4,306
|
Quote:
|
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#5 |
Confirmed User
Industry Role:
Join Date: Nov 2009
Location: Heaven
Posts: 4,306
|
i got it,
search for /getdownloadmanager.php\?([^\"]*)\">/iU i.e. # starts with: getdownloadmanager.php? # a series of characters up to, but not including, the next double-quote (") - 1st capture # the string: "> |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#6 |
Confirmed User
Join Date: Dec 2005
Posts: 271
|
Dunno if this will work i just typed it in here havn't tested.
Code:
/^(http:\/\/jump2link.net\/watch\/getdownloadmanager.php?movie=){1}.+(1321){1}$/ |
![]() |
![]() ![]() ![]() ![]() ![]() |