It is currently Thu 09 Sep, 2010 12:40

All times are UTC




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: A new way to setup context["robots"]
PostPosted: Fri 22 Feb, 2008 15:15 
Offline
Administrator

Joined: Wed 12 Oct, 2005 04:50
Posts: 973
Location: duisburg, germany
In v0.8.0 the context variable "robots" doesn't changed right :(

So i only want to bugfix this... A least i change the way to build this dynamic variable... But i don't think this is relay the best way.

Please look here:
http://trac.pylucid.net/changeset/1440

I have create a docu page for this variable, too:
http://pylucid.org/_goto/140/context-robots/

Any feedback?

_________________

http://www.jensdiemer.de | http://www.htfx.de | http://www.python-forum.de


Top
 Profile  
 
 Post subject:
PostPosted: Tue 26 Feb, 2008 08:12 
Offline
Administrator

Joined: Wed 12 Oct, 2005 04:50
Posts: 973
Location: duisburg, germany
A new idea: Don't put the robots value ("index,follow" or "NONE,NOARCHIVE") directly into the context -> Put only the bool "anonymous_view" into the context!

Then we can make this:
Code:
<meta name="robots" content="{% if anonymous_view %}index,follow{% else %}NONE,NOARCHIVE{% endif %}" />


We can used the "anonymous_view" information in other way, too. e.g. for a google adsense block and for this:
Code:
{% if not anonymous_view %}<div id="admin">{% lucidTag admin_menu %}</div>{% endif %}


With this, we have another benefit: The plugin manager variable "no_rights_error" is obsolete and we can remove the code for this! Nice.

We should remove "robots" from the context in v0.9 so the changes are not backwards-incompatible, now.

remove "robots" and "no_rights_error" in v0.9: http://trac.pylucid.net/ticket/161
add "anonymous_view" in http://trac.pylucid.net/changeset/1447

_________________

http://www.jensdiemer.de | http://www.htfx.de | http://www.python-forum.de


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group