Solved

Replace Help

Posted on 2011-03-09
2
281 Views
Last Modified: 2012-05-11
I'm trying to build a query for mysql that I can execute from phpmyadmin that will replace the following:

Video Description

to

[media]http:domain.com/video/video.flv[/media]

the length of the domain could change and the file format could change also, so I'm not sure how to do this.  Any suggestions?

The reason I'm doing this is I just recently moved to IPB and my old embed codes will not work on it.  I was using Avea Media on SMF forums to embed my links, but no mod for this on IPB just BBCodes.
0
Comment
Question by:N R
2 Comments
 
LVL 15

Accepted Solution

by:
Jagadishwor Dulal earned 500 total points
ID: 35092791
You can add the domain name in a variable like
$domname="http://www.domain.com/";
and when you fetch your record of meida file concatenate your domain and video location like:
$video=$row['medialocation'];
echo $domname.$video;//for video file full path
0
 
LVL 11

Author Comment

by:N R
ID: 35094522
I need to update the records within the post table within mysql.
0

Featured Post

Ransomware: The New Cyber Threat & How to Stop It

This infographic explains ransomware, type of malware that blocks access to your files or your systems and holds them hostage until a ransom is paid. It also examines the different types of ransomware and explains what you can do to thwart this sinister online threat.  

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

These days, all we hear about hacktivists took down so and so websites and retrieved thousands of user’s data. One of the techniques to get unauthorized access to database is by performing SQL injection. This article is quite lengthy which gives bas…
When table data gets too large to manage or queries take too long to execute the solution is often to buy bigger hardware or assign more CPUs and memory resources to the machine to solve the problem. However, the best, cheapest and most effective so…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question