Archive for April 8th, 2008

now that was enough fun with W…

Posted by admin on April 8th, 2008

now that was enough fun with WordPress, let’s get down to programming Ruby again…

[Slashdot] [Digg] [Reddit] [del.icio.us] [Facebook] [Technorati] [Google] [StumbleUpon]

Password protected posts

Posted by srejbi on April 8th, 2008

Another WordPress based website I maintain, happened to have some password protected posts. Once the password protection was enabled on the post, I visited the page to see if everything works properly. Surprisingly every time I submitted the password, I have found myself on the same page, demanding the password on and on.

I have spent quite a few minutes meditating on this, then checked the form in the source. It is redirecting to wp-pass.php, which verifies the password submitted, and sets a cookie called post_password (default expiry: 864000 seconds /=10 days/, if anyone cares to change it, it can be done by editing this file /I could not leave this as reply to this post, or this one due to that both topics are closed) then redirects to the referrer (that will check the password from the cookie, I suppose). This seemed alright to me.

Browsing through my settings, I found that for some reason the website had different URL’s entered for WordPress address (URL) and Blog address (URL) under the General Settings. The two URL’s were in different domains (so imagine not www.somedomain.com and admin.somedomain.com, but www.somedomain.com and admin.anotherdomain.com) Thinking about the cookie and the redirect in wp-pass.php I have changed the WordPress address (URL) to be the same as the Blog address (URL), and all of the sudden the password protection started working as expected, requesting password only once (if the proper code is entered, of course :) ).

Asking me why?
Cookies store the host’s domain name and apparently this is is the WordPress address, not the Blog address for the post passwords… I was not looking into it deeper than this (for me it was ok to change the domain names in the settings), probably there is a way around this by changing some of the WordPress code, but I will likely leave that for the project developers… :)

I have been googling on this for some time, but found no traces of this problem and workaround… Is anyone out there? Enjoy! :)

[Slashdot] [Digg] [Reddit] [del.icio.us] [Facebook] [Technorati] [Google] [StumbleUpon]

bugging with wordpress…

Posted by admin on April 8th, 2008

bugging with wordpress…

[Slashdot] [Digg] [Reddit] [del.icio.us] [Facebook] [Technorati] [Google] [StumbleUpon]

now that was a long shower… …

Posted by admin on April 8th, 2008

now that was a long shower… had some cold showers of work in the meantime, a happy easter and some more drops of work… and working again

[Slashdot] [Digg] [Reddit] [del.icio.us] [Facebook] [Technorati] [Google] [StumbleUpon]