Forum Moderators: Robert Charlton & goodroi

Message Too Old, No Replies

Upgrade to HTTPS - Absolute vs. Relative Links?

         

DChan

8:28 pm on Jun 6, 2017 (gmt 0)

5+ Year Member Top Contributors Of The Month




NOTE: Quoted post from thread where this discussion originated: [webmasterworld.com...]


This has been posted a few times, but maybe should be posted in this thread as well:

- Generic Steps to Switch from HTTP to HTTPS -

• Read all info at your host concerning certificates & switching to HTTPS and when applicable, follow those instructions.

• Install security certificate.

• Have you host enable HTTPS (if needed.) This will enable access from both HTTP & HTTPS.

• Go through site, page by page & make sure all file paths are relative (no protocol.) Test by accessing site using HTTPS and look for any browser alerts.

• Install 301 code in .htaccess file
RewriteEngine On
RewriteCond %{HTTPS} !=on
RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
Note: your server may require a different code

• Go through site again, page by page, and test. Any remote absolute links will need to be HTTPS including those found in scripts & pluggins. If you publish Adsence or other advertising, links in these scripts need to be HTTPS also (or just remove the protocol altogether.)

• Update sitemap.xml (if applicable) and submit to appropriate agencies (Google, Bing, Yandex, etc)

• In Google Search Council create a new site using HTTPS (do not use the Change of Address form.) It will take a few days to start populating information. This is normal & traffic to old site (HTTP) will drop off accordingly.

• Bing Webmaster Tools, Yandex & others should update automatically once they crawl your new pages. Updating/re-submitting sitemap.xml should speed up this process.


" Go through site, page by page & make sure all file paths are relative (no protocol.) Test by accessing site using HTTPS and look for any browser alerts."

Why I ask this is because I just changed over to https and my web host changed all my urls to relative from absolute (all my urls were absolute since approx. 2007). I have been working to change them back to absolute. Am I misunderstanding but from your comment above are you saying we should not be using absolute protocol urls (https://) even for image links?




[edited by: not2easy at 8:18 pm (utc) on Jun 13, 2017]
[edit reason] Added quote from original Thread [/edit]

keyplyr

3:01 am on Jun 7, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



You have a lot of pages. You have been changing a lot of things. IMO having two conflicting sitemaps may have caused some indexing concerns. Now that it has been corrected, give it some time.

It can take a week or more for all those pages to get indexed. Some members have reported it takes even longer for 1k+ pages. The old HTTP pages will drop off the index as the new HTTPS pages are added.

DChan

3:13 am on Jun 7, 2017 (gmt 0)

5+ Year Member Top Contributors Of The Month



Ok, thank you, keyplyr. I hope this straighten things up now. You all are great, thank you so much for being here!

not2easy

4:38 am on Jun 8, 2017 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



I just stumbled onto a relevant bit of information from Google regarding the use of relative URLs [developers.google.com] for intrasite links - they recommend that you do not use full URLs, but either relative URLs (href="/filename.html") or protocol-relative URLs (href="//directory/filename.html") for your intrasite links. A lot of the information discussed here is covered there also. The first half of their page is about how to generate your CSR and get a SSL Certificate installed. About half way down the page they get into this topic.

DChan

12:57 pm on Jun 8, 2017 (gmt 0)

5+ Year Member Top Contributors Of The Month



My site was migrated to https on May 19th. According to GSC for the http property, only 158 out of 1238 http urls are still indexed and over 1200 https urls are indexed now. So would this "now that you are serving your site on both HTTP and HTTPS" still apply to me?

DChan

1:48 pm on Jun 8, 2017 (gmt 0)

5+ Year Member Top Contributors Of The Month



I am wondering if this is part of the problem on my site. I checked my site in the SSL Check feature at the following link: [jitbit.com...] And it shows all pages it crawled (199), all 199 pages with unsecure content. One each of the pages, the following code was giving each page the unsecure content error:

"http://storage.ie6countdown.com/assets/100/images/banners/warning_bar_0000_us.jpg"

This is in the header of my website's template. When I got this template I saw these codes but thought I was suppose to leave them or the page may not work right, here is the full code:

<!--[if lt IE 8]>
<div style=' clear: both; text-align:center; position: relative; top: 11px; left: -11px;'>
<a href="http://windows.microsoft.com/en-US/internet-explorer/products/ie/home?ocid=ie6_countdown_bannercode">
<img src="http://storage.ie6countdown.com/assets/100/images/banners/warning_bar_0000_us.jpg" border="0" height="42" width="820" alt="You are using an outdated browser. For a faster, safer browsing experience, upgrade for free today." />
</a>
</div>
<![endif]-->
<!--[if lt IE 9]>
<script src="js/html5.js"></script>
<script src="js/css3-mediaqueries.js"></script>
<![endif]-->

Is it safe to remove this so it doesn't give the unsecure content error and/or should it be replaced with some other directive for IE8 and IE9 that doesn't give such an error in HTTPS?

lucy24

4:12 pm on Jun 8, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Oh, for ### sake. Every single page has an individual piece of code directed purely at people using (or robots claiming to use) MSIE 7 and below? Why the ### would something like that ever be necessary?

Even if your site happens to include material that won't display adequately on MSIE < 8, that's the user's business.

Bloat. Get rid of it.

:: wandering off to see when I last met a human using MSIE < 8 ::

Oh, and by the way, that linked URL beginning in http://windows.microsoft.com/ ? It now redirects to a generic MSIE page ... in https.

:: returning from search (which was running in the background all this while) ::

My goodness, what a lot there still are. But you have to postulate (a) elderly hardware that won't support an OS newer than suchandsuch, leading to (b) elderly OS that won't support a browser newer than MSIE 7. But what's the point of nagging at users to tell them something they already know and is out of their power to change? It's like telling someone they ought to be making more money.

otoh, unless you're aiming at a very unusual demographic, you can safely exclude MSIE 6 and below. MSIE 7 seems to be the watershed.

But we digress ;)

directive for IE8 and IE9
Note that it isn't 8 and 9. It's below 8 and below 9. Big difference.

keyplyr

7:36 pm on Jun 8, 2017 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



One each of the pages, the following code was giving each page the unsecure content error:
"http://storage.ie6countdown.com/assets/100/images/banners/warning_bar_0000_us.jpg"
While that and any othe non-secure link needs to be fixed, it will not impact your HTTPS pages being indexed.

DChan

8:29 pm on Jun 8, 2017 (gmt 0)

5+ Year Member Top Contributors Of The Month



I now have the non-secure links fixed on the pages. Hope this will straighten things out. My https urls are being indexed fine, so far Google has indexed 1225 out of 1331 urls submitted. Bing has indicates they have indexed 1,983 urls.
This 38 message thread spans 2 pages: 38