Go Back   vb.org Archive > Community Discussions > Forum and Server Management
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 05-13-2009, 11:58 PM
MuSuL MuSuL is offline
 
Join Date: Sep 2002
Posts: 76
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Changed domains, looking for a hack

I changed my domain and I'm looking for a hack that will take all my internal links (i.e. links in a thread that point to another thread on my forum) and change it to the new domain name.

Does something like this exist?
Reply With Quote
  #2  
Old 05-14-2009, 12:46 AM
fattony69 fattony69 is offline
 
Join Date: Jun 2007
Location: Philly
Posts: 353
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Seems like all you need is .htaccess
Reply With Quote
  #3  
Old 05-14-2009, 12:49 AM
MuSuL MuSuL is offline
 
Join Date: Sep 2002
Posts: 76
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I don't have access to the old domain.

Is there something I can do on the new one? Can you explain?
Reply With Quote
  #4  
Old 05-14-2009, 02:47 AM
fattony69 fattony69 is offline
 
Join Date: Jun 2007
Location: Philly
Posts: 353
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Oh, you don't have access to the other domain?

You are going to have a problem. You need that. You put an .htaccess file to redirect users, but since you don't have it, you can't do that. You might not be able to do anything.
Reply With Quote
  #5  
Old 05-14-2009, 04:03 AM
veenuisthebest's Avatar
veenuisthebest veenuisthebest is offline
 
Join Date: Mar 2008
Location: India
Posts: 1,416
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

lol if you don't own the older domain now, how can you control it. As said above, you have to park the old domain and with few lines of htaccess rewrites its really easy to do.
Reply With Quote
  #6  
Old 05-18-2009, 03:15 AM
COBRAws's Avatar
COBRAws COBRAws is offline
 
Join Date: Oct 2002
Location: Buenos Aires
Posts: 864
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hey guys, his problem is that he needs the posted links (links to other parts of his forum) to update those URL's with the new domain.

MuSuL, you will have to do a search and replace kinda thing, the only possible solution would be to go phpMyAdmin and do it thru there.
Reply With Quote
  #7  
Old 05-18-2009, 01:24 PM
snakes1100 snakes1100 is offline
 
Join Date: Dec 2001
Location: Michigan
Posts: 3,733
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by COBRAws View Post
Hey guys, his problem is that he needs the posted links (links to other parts of his forum) to update those URL's with the new domain.


MuSuL, you will have to do a search and replace kinda thing, the only possible solution would be to go phpMyAdmin and do it thru there.
There is no need to go into PMA and change anything as your directing, the answer was given already, a simple htaccess rewrite rule of the old domain will suffice.

@MuSul, post in the programming section and see if someone will help you write the needed htaccess rewrite rule or post in the paid job forum for a paying job if no one will do it for free.
Reply With Quote
  #8  
Old 05-18-2009, 03:59 PM
MuSuL MuSuL is offline
 
Join Date: Sep 2002
Posts: 76
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I had gone ahead and edited all 1200 of them. I was thinking on writing a piece of code but it only took 2 hours to do it manually. No biggie.

What would the .htaccess file have looked like? I don't have experience with them.
Reply With Quote
  #9  
Old 05-18-2009, 05:43 PM
UKBusinessLive UKBusinessLive is offline
 
Join Date: Sep 2008
Location: Essex, United Kingdom
Posts: 1,637
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by MuSuL View Post
I had gone ahead and edited all 1200 of them. I was thinking on writing a piece of code but it only took 2 hours to do it manually. No biggie.

What would the .htaccess file have looked like? I don't have experience with them.
An Example .htaccess file looks something like this

PHP Code:
Options +FollowSymLinks 
RewriteEngine on

RewriteCond 
%{HTTP_HOST} ^www.old-domain.com$ [NC]
RewriteRule ^(.*)$ http://www.new-domain.com/$1 [R=301,L] 
That would delivert all traffic from the "old" domain to the "new

Just edit the above and save it to your desktop as htaccess.txt

Then upload this file to your root directory, once there rename it to .htaccess

Notice where the dot is and that the .txt has now disappered, thats it
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 12:09 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04723 seconds
  • Memory Usage 2,244KB
  • Queries Executed 13 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)bbcode_php
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (9)post_thanks_box
  • (9)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (9)post_thanks_postbit_info
  • (9)postbit
  • (9)postbit_onlinestatus
  • (9)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete