hashbang

Linked in share and hashbang url

回眸只為那壹抹淺笑 提交于 2021-02-08 08:52:26
问题 I have a question about linkedin and sharing url with hashbang (angular app). It seems like if the hashbang is right after first slash (www.example.com/#!/someString) the LinkedIn bot will issue request for www.example.com/ . But if the shared url is like www.example.com/someString/#!/otherString linkedin bot issue request for www.example.com/someString/?_escaped_fragment=/otherString . Do you have some working solution for sharing hashbang urls? I found one stackoverflow question from 2013,

Redirect from Hash to HashBang using angular

…衆ロ難τιáo~ 提交于 2020-01-06 04:31:19
问题 I have published a website using mvc c# with angular and AJAX calls to create some client side pages. One of my links look like this: www.website.com/App#/Index I am trying to setup a hasbang solution to make my site crawlable. I succesfully created the hashbang setup so now a working link will look like this: www.website.com/App#!/Index The issue now is that all my links out on Facebook and so on does not contain the bang (!) and therefore those links are dead. How do I redirect from the

How to do a specific condition for escaped_fragment with rewrite rule in .htaccess

你。 提交于 2019-12-24 03:53:36
问题 I have urls like that /#!/page1 , I redirect them with : RewriteCond %{QUERY_STRING} ^_escaped_fragment_=%2F(.*)$ RewriteRule ^$ /seo/%1.html [QSA,L] So /#!/page1 read as /_escaped_fragment_=%2Fpage1 is redirected to /seo/page1.html It's work perfectly however I want to redirect the home /#!/ to /seo/index.html which actually redirect to /seo/.html How can I do that? Thanks 回答1: I fixed it with: RewriteCond %{QUERY_STRING} ^_escaped_fragment_=%2F$ RewriteRule ^$ /seo/index.html [QSA,L]

How to do a specific condition for escaped_fragment with rewrite rule in .htaccess

做~自己de王妃 提交于 2019-12-24 03:53:07
问题 I have urls like that /#!/page1 , I redirect them with : RewriteCond %{QUERY_STRING} ^_escaped_fragment_=%2F(.*)$ RewriteRule ^$ /seo/%1.html [QSA,L] So /#!/page1 read as /_escaped_fragment_=%2Fpage1 is redirected to /seo/page1.html It's work perfectly however I want to redirect the home /#!/ to /seo/index.html which actually redirect to /seo/.html How can I do that? Thanks 回答1: I fixed it with: RewriteCond %{QUERY_STRING} ^_escaped_fragment_=%2F$ RewriteRule ^$ /seo/index.html [QSA,L]

why do `#!/usr/bin/env var=val command` gets into an infinite loop

試著忘記壹切 提交于 2019-12-23 18:29:53
问题 In man(1) env it say: env [OPTION]... [-] [NAME=VALUE]... [COMMAND [ARG]...] So consider print_A.sh : #!/usr/bin/env A=b bash echo A is $A When I run it with ./print_A.sh it hangs. Running it with strace ./print_A.sh I get the following log, repeating: execve("/path/to/print_A.sh", ["/path/to/print_A.sh"...], [/* 114 vars */]) = 0 uname({sys="Linux", node="my-host", ...}) = 0 brk(0) = 0x504000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2a95556000 access("/etc

Backbone.js PushState routes .htaccess only working as hash but nowhere else

好久不见. 提交于 2019-12-23 16:49:57
问题 I have a website domain.com for example. I have backbone.js with pushstate and fallback and when I goto domain.com/about it loads up the index.html page and pushstates to about. everything is working. but if i want to goto a directory with a page inside like: www.domain.com/bio/moreinfo for example, it does not work and throws a invalid page. if i do it in IE it works fine. my htaccess file has the following: RewriteEngine on # html5 pushstate (history) support: <ifModule mod_rewrite.c>

Empty URL hash causes page to jump on js events

送分小仙女□ 提交于 2019-12-22 09:46:30
问题 I have a gallery of photos with a next and previous button. If one of my javascript methods is broken for one reason or another when one of the buttons is clicked it will add a hash to the url i.e. www.google.com# . I know the hash can be given a div id to jump to that part of the page but when it's blank it jumps around my page a few times and I'm not sure what it's targeting. I thought of attempting to remove the hash from the url but then I'd have to ensure that on every action and that

jQuery Mobile and “query parameters” for hashbang navigation

二次信任 提交于 2019-12-21 09:03:42
问题 I am using jQuery Mobile and have few pages in one HTML page. When opening these pages, I'd like to pass parameters for them, so that their parameters are persistent in URL. E.g. <a href="#map?x=4&y=2" It would open and I could access parameters X and Y in beforeshow event. Is this possible and how? What alternative means you suggest for encoding parameters with hashbangs? 回答1: Yes, you can have links like the one you showed: <a href="#map?x=4&y=2"> Click here </a> Then, on before show you

jQuery Mobile and “query parameters” for hashbang navigation

懵懂的女人 提交于 2019-12-21 09:03:34
问题 I am using jQuery Mobile and have few pages in one HTML page. When opening these pages, I'd like to pass parameters for them, so that their parameters are persistent in URL. E.g. <a href="#map?x=4&y=2" It would open and I could access parameters X and Y in beforeshow event. Is this possible and how? What alternative means you suggest for encoding parameters with hashbangs? 回答1: Yes, you can have links like the one you showed: <a href="#map?x=4&y=2"> Click here </a> Then, on before show you

How to disable the #hashbang redirect on IE8 and IE9 in angularjs

感情迁移 提交于 2019-12-21 04:17:07
问题 I have an angularjs (v 1.2.19) application that consists of two separate html pages (or actually these are two seperate angularjs apps in one folder): index.html edit.html I am having some well-known compatibility issues on IE 8 and 9 (both do not support the html5 history API). My config contains: $locationProvider.html5Mode(true).hashPrefix('!'); I do not have any routing in the application - index.html and edit.html can be seen as separate angularjs apps - that have separate angularjs