• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Adding http:// to existing url's

Community Beginner ,
Feb 02, 2018 Feb 02, 2018

Copy link to clipboard

Copied

I've been running my site successfully for years, coded with Dreamweaver CS3.

In the last few weeks my Adsense ads (size 160 x 600) have sometimes been replaced with a panel (of the same size) from my server saying that 'the page (advert) cannot be found' (apparently error 404).

My 'Server's Help' say I should add http:// in front of all page URL's. First I'm wondering how I managed for all these years without it, but mainly how do I add the http:// on over 150 pages, and hopefully without having to edit each page individually.

Views

229

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , Feb 02, 2018 Feb 02, 2018

In CC 2017 or later, hit Ctrl/Cmnd + Shift + F to open the Find & Replace tool.
Click the Basic Tab
In the first large field (unlabeled Find field), add the entire code of the link (<a href="//path-to/link.html">)

For the "In" dropdown menu, choose Entire Current Local Site
Leave the next field as [any tag]
In the second large field (unlabeled Replace With field) add the entire code of the new link (<a href="http: //www.path-to/link.html">)
Hit Replace All

Votes

Translate

Translate
Community Expert ,
Feb 02, 2018 Feb 02, 2018

Copy link to clipboard

Copied

In CC 2017 or later, hit Ctrl/Cmnd + Shift + F to open the Find & Replace tool.
Click the Basic Tab
In the first large field (unlabeled Find field), add the entire code of the link (<a href="//path-to/link.html">)

For the "In" dropdown menu, choose Entire Current Local Site
Leave the next field as [any tag]
In the second large field (unlabeled Replace With field) add the entire code of the new link (<a href="http: //www.path-to/link.html">)
Hit Replace All

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 02, 2018 Feb 02, 2018

Copy link to clipboard

Copied

you can also use a reg exp in the search and replace files ({ctrl|cmd} shift f

think to check the use of regular expression and search for

href="(?!http*://)

that you will replace with

href="http://

if you not used to regex... the search will focus on all string starting by href=" and not icnlude http with a facultative s and followed by ://

that way you will only replace the url link that doesn't use any protocol

be aware of depending on your web site, the reg ex can be adjusted

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Feb 02, 2018 Feb 02, 2018

Copy link to clipboard

Copied

LATEST

But back up your site folder first incase anything hideously goes wrong.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines