Home Forum
2024-12-22
Benvenuto, Ospite
Nome Utente Password: Ricordami

redirect to the same url with an anchor at the end
(1 Online) (1) Ospite
  • Pagina:
  • 1
  • 2

ARGOMENTO: redirect to the same url with an anchor at the end

redirect to the same url with an anchor at the end 14 Anni, 2 Mesi fa #1517

  • boucdur
  • Offline
  • Fresh Boarder
  • Messaggi: 8
Hello, buongiorno,

I don't get much about url url redirecting.
What I try to do seems simple though :

I want to redirect all the articles of my blog to same page but to an anchor.

These are my urls for the articles of my blog. Tymate is the category name.
www.francois-rosenbaum.com/tymate/article1
www.francois-rosenbaum.com/tymate/article2
www.francois-rosenbaum.com/tymate/article3

I would like the visitor to be redirected to these pages when they try to acceed one of the above urls :
www.francois-rosenbaum.com/tymate/article1#ancre_blog
www.francois-rosenbaum.com/tymate/article2#ancre_blog
www.francois-rosenbaum.com/tymate/article3#ancre_blog

Thanks for your help.
Grazie
L'Argomento è stato bloccato.

Re: redirect to the same url with an anchor at the end 14 Anni, 2 Mesi fa #1519

  • admin
  • Offline
  • Administrator
  • Messaggi: 1603
Sorry,
are you saying you just need to add "#ancre_blog" at the end of those URLs?

Luigi
L'Argomento è stato bloccato.

Re: redirect to the same url with an anchor at the end 14 Anni, 2 Mesi fa #1522

  • boucdur
  • Offline
  • Fresh Boarder
  • Messaggi: 8
That's exactly what I am saying.

I just need to add "#ancre_blog" at the end of all the urls which have the category "tymate".

I read carrefully the complete documentation about redj. But I could not get the redirection to work. Actually I cannot get no redirection to work.

Would you know what I should write to redirect all the links with tymate in them to the same locations but with #ancre_blog at the end.

So this is a a dynamic redirection I need.

I am lost.
L'Argomento è stato bloccato.

Re: redirect to the same url with an anchor at the end 14 Anni, 2 Mesi fa #1523

  • admin
  • Offline
  • Administrator
  • Messaggi: 1603
You are right,
macro in destination URL can help:

www.francois-rosenbaum.com/tymate/article1

From URL: /tymate/
To URL: http://{siteurl}{path}#ancre_blog


I'm assuming you haven't query vars in your URLs. If not so, just change:

From URL: /tymate/
To URL: http://{siteurl}{path}{queryfull}#ancre_blog


Regards,
Luigi
Ultima modifica: 14 Anni, 2 Mesi fa Da admin.
L'Argomento è stato bloccato.

Re: redirect to the same url with an anchor at the end 14 Anni, 2 Mesi fa #1526

  • boucdur
  • Offline
  • Fresh Boarder
  • Messaggi: 8
Hi Luigi,

thank you for your answer.
I tried it.
Unfortunatly it doesn't work. And I really don't see why.

If you have the time to check it :
here is the adress :
www.francois-rosenbaum.com/#ancre_blog

And here are the codes to access the backend :
luigi
*****

thank you for your help,

Francois
Ultima modifica: 14 Anni, 2 Mesi fa Da admin.
L'Argomento è stato bloccato.

Re: redirect to the same url with an anchor at the end 14 Anni, 2 Mesi fa #1527

  • boucdur
  • Offline
  • Fresh Boarder
  • Messaggi: 8
Hello,

Thank you for your message Luigi,
Unfortunatly the solution didn't work and I don't know why.

I give you all the access to the website in case you have the time to have a look at it directly.
www.francois-rosenbaum.com/#ancre_blog

access to backend :
luigi *****

So what I would like :
when the visitor click on the title of an article in the blog I would like him to be redirected to the normal page (the one generated by joomla) but on the right side. So for that I need to redirect the visot to the same page but with #ancre_blog at the end. just as I explained in my other messages.

Regards,

François
Ultima modifica: 14 Anni, 2 Mesi fa Da admin.
L'Argomento è stato bloccato.

Re: redirect to the same url with an anchor at the end 14 Anni, 2 Mesi fa #1528

  • boucdur
  • Offline
  • Fresh Boarder
  • Messaggi: 8
Actually,

To be precise : the redirection apparently works because when I click on the title of an article I arrive on the right url with #ancre_blog, the url seems as I wanted.
However I get nothing on the page but a message telling me the page is not redirected correctly.
L'Argomento è stato bloccato.

Re: redirect to the same url with an anchor at the end 14 Anni, 2 Mesi fa #1529

  • admin
  • Offline
  • Administrator
  • Messaggi: 1603
I'm going to check now.

Please, don't post credentials on the forum (I've edited message replacing the password with stars).

To send me private message use email at info(at)sistemistica.it.

Regards,
Luigi
L'Argomento è stato bloccato.

Re: redirect to the same url with an anchor at the end 14 Anni, 2 Mesi fa #1530

  • admin
  • Offline
  • Administrator
  • Messaggi: 1603
Sorry,
but I was so stupid to tell you this redirect could work. It is not possible at all!

This is the reason. You just need to add the fragment to the URL, but the fragment is just an anchor to a point in the page. When a browser must follow an URL with the fragment part, drop it from the request. I mean, when you say to the browser to call the link:

www.francois-rosenbaum.com/component/content/article/28-euratechnologies-laboratoire-des-nouvelles-technos#ancre_blog

It calls always:

www.francois-rosenbaum.com/component/content/article/28-euratechnologies-laboratoire-des-nouvelles-technos

And then search for anchor in the page. You can test it by yourself.

So, there's no way to stop loop in the redirect. And this is the reason why I don't create a macro for the fragment part (I already knew that was not needed, now I just forgot it, maybe I need an holyday).

You should create your page links with the fragment you need. Maybe you could find a plugin that does this.

Regards,
Luigi
Ultima modifica: 14 Anni, 2 Mesi fa Da admin.
L'Argomento è stato bloccato.

Re: redirect to the same url with an anchor at the end 14 Anni, 2 Mesi fa #1531

  • boucdur
  • Offline
  • Fresh Boarder
  • Messaggi: 8
So if I understand it is impossible to do what I want with a redirection and your telling me that I have to change the urls generated by joomla for the article ?

Is that it ?
L'Argomento è stato bloccato.
  • Pagina:
  • 1
  • 2
Moderatori: admin
Tempo generazione pagina: 0.51 secondi
Cerca con Google
News
Chi è online
 145 visitatori online
Sponsor

slotmachineaamsonline.com è una guida alle migliori slot machine online legali in Italia. Sul sito trovi un elenco sempre aggiornato dei casino online con Slot machine e bonus slot, le ultime novità dal mondo delle slot online e le migliori strategie per vincere. Inoltre, è disponibile una sezione dedicata alle slot machine da BAR che finalmente sono disponibili nella versione online.