TinyPortal
Development => Support => Topic started by: Wichtlmex on May 31, 2019, 01:55:17 PM
I am building atest site right now. If everything works, I would like to move to a different domain.
I see there are many absolute links to images etc. Is it anyway possible to manage a relocation without too much extra work?
Regards
Michael
Fist of all, try to stay away from absolute links as much as possible:
in articles this code works just as well as the complete path:
Relative: <img src="/Documenten/Images/Illustraties/Techniekdag_2009.JPG>
Absolute: <img src="https://test.fjr-club.nl/Documenten/Images/Illustraties/Techniekdag_2009.JPG>
Links in menu options etc in TP will work: they are relative to the ID's of the article linked too..
Depending on how different the URLs will be you could also use MySQL's REPLACE() (https://dev.mysql.com/doc/refman/5.7/en/string-functions.html#function_replace) function to update things via phpMyAdmin...
UPDATE table SET column=REPLACE(column, 'oldtext', 'newtext');
Note that you should back up your database before trying this and it may take a while on larger forums or forums with a lot of large posts.