Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

problems with URLs to share with google plus

Posted on 2014-02-23
7
Medium Priority
?
223 Views
Last Modified: 2014-03-01
hi
I have sharing on my site for other services and it works great. I wanted to add a google plus share button. so I checked google and I use this code:

<!-- Place this tag where you want the +1 button to render. -->
<div class="g-plusone"></div>

<!-- Place this tag after the last +1 button tag. -->
<script type="text/javascript">
  (function() {
    var po = document.createElement('script'); po.type = 'text/javascript'; po.async = true;
    po.src = 'https://apis.google.com/js/platform.js';
    var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(po, s);
  })();
</script>

Open in new window


my site is multi language one. I have no problems sharing in the Hebrew section of the site but cannot share the url in the English section.

an example from the Hebrew section:
http://shtigliz.com/page/about

an example from the English section:
http://shtigliz.com/page/abouten

when I try to share manually I get the same result: the Hebrew one is accepted while the English one I get the message: cannot load the site.

what am I missing here?
0
Comment
Question by:derrida
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
7 Comments
 
LVL 58

Expert Comment

by:Gary
ID: 39880762
You have temporary (302) redirects on the url.  You also have one on the Hebrew as well but it may be that Google already has a copy of the page so it doesn't need to check it again.
0
 
LVL 1

Author Comment

by:derrida
ID: 39882108
i have changed my function code to this, mod rewrite is on.

 header("HTTP:/1.1 301 Moved Permanently");
                    header ( "Location: {$location}" ) ;
                    exit();

Open in new window


nothing has changed.

any idea?

maybe google just need time?
0
 
LVL 58

Expert Comment

by:Gary
ID: 39883025
Why are you doing a redirect in the first place, you are just redirecting to the same page
Anyway your site is still doing a 302 redirect and a 301 redirect.
0
Stressed Out?

Watch some penguins on the livecam!

 
LVL 1

Author Comment

by:derrida
ID: 39883426
redirect to another action in the same controller according to the required action.
0
 
LVL 58

Accepted Solution

by:
Gary earned 2000 total points
ID: 39883505
I don't know what server side language you are using but your router should not be redirecting like that - that should be an internal thing, not something you are sending to the browser
0
 
LVL 1

Author Comment

by:derrida
ID: 39884951
I will check that out. but why I have no issue with the same urls with facebook and others?
0
 
LVL 58

Expert Comment

by:Gary
ID: 39886139
Off the top of my head I cannot remember how Facebook checks the url but Google checks it every time.
0

Featured Post

TCP/IP Network Protocol Cheat Sheet

TCP/IP is a set of network protocols which is best known for connecting the machines that make up the Internet. The truth is that TCP/IP is one of the oldest network protocols and its survival is mainly based on its simplicity and universality.

Question has a verified solution.

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

JavaScript can be used in a browser to change parts of a webpage dynamically. It begins with the following pattern: If condition W is true, do thing X to target Y after event Z. Below are some tips and tricks to help you get started with JavaScript …
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…
Suggested Courses

721 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