The tag has no wiki summary.

learn more… | top users | synonyms

1
vote
1answer
2k views

How to get login data (session) outside WordPress?

I guess WP uses a PHP session (or a cookie) to save login data, right? I have a website, which uses WP as a CMS, but display (and create) content from outside. I allow anonymous posts, by simply not ...
0
votes
0answers
64 views

Accept (once only) policy page on login

I'm developing a simple application on WP that requires the user to accept a policy page on first login. If they accept, they're redirected somewhere (homepage), if not, they're redirected somewhere ...
0
votes
1answer
938 views

Secure wordpress_logged_in cookie

I have to make sure, that the Wordpress cookie set after successful log in, "wordpress_logged_in_[salt-sth]" is set to be available for secure connections only. It looks like that it´s a filter used ...
0
votes
1answer
198 views

Using a nonce in a Custom Login Form

I am trying to create my own login form for WordPress using wp-login.php as a template. In the form that is used to collect login information from the user (lines 680 through 703 of wp-login.php), ...
3
votes
4answers
5k views

How to validate a user from ouside wordpress/php?

I'm working on an ajax application that will be embedded in a wordpress page. The ajax app exchanges data with servlets running on tomcat. Now the servlets need a way to determine if a request comes ...
0
votes
1answer
24 views

How to save a viewer specific option

A minimal example of my problem would be default background colour is white a custom sidebar widget offers to switch background colour to green when switched to green, background shall stay green ...
1
vote
1answer
527 views

Set authentication cookies to be shorter but then extend with every page load

I'm trying to get around the otherwise very insecure way of Wordpress handling authentication cookies. I mean, having the cookie expire in 2 weeks only if I build a membership site is obviously not ...
0
votes
0answers
456 views

WP Logs me out after updating anything on dashboard

Not sure what is going on here but my live site kicks the admin out every time they change something in the dasboard. For instance when an admin updates a page the url looks like ...
1
vote
3answers
647 views

Setting a redirect cookie in wordpress

I've been searching on the net for a solution to my problem all day, but I can't make sense of anything I see, since I know absolutely NOTHING about coding. What I'd like to do: I'd like to set a ...
0
votes
1answer
73 views

Caching for logged in user and Ajax update

I would want to serve the homepage with a cached version of the page for both logged in and new users. And then to use Ajax to update the content appropriately, for example if the user had already ...
3
votes
1answer
961 views

Clearing cookie on logout and session expiration

I would like to clear the session cookie when a user logs out or when their session expires. I understand that wp_clear_auth_cookie(); clears the cookie but I am struggling to understand how to ...
5
votes
2answers
373 views

Passing current cookies in wp_remote_get to get Draft Post Preview

I want pass current user cookies in wp_remote_get function to get a Draft Post Preview page content. I check already the questions: What URL do you pass to wp_remote_get to load the body of the ...
0
votes
2answers
561 views

Detecting $_GET parameters from any page + Cookie

I'm trying to create a basic affiliation system plugin that for now, will do the following: If it exists, read a $_GET URL parameter in any page (for instance http://mysite.com/about/?affid=1234). ...
0
votes
1answer
214 views

How to keep a variable in COOKIE or GET query string?

I'm working on adding a language variable (locale) in my custom WordPress theme. I made the translation working by adding ?l=en_US to the URL. I would like to add the parameter into COOKIE, such that ...
1
vote
1answer
345 views

Cookie value cannot be read until I've logged into the WP admin

Once logged into the WP admin, I can refresh the front-end and see my cookie's value outputted as "hello world". If I log out of the admin, then refresh my front-end, the cookie's value is now ...
1
vote
1answer
300 views

Serving Cookies From A Different Domain or Sub-Domain

The WordPress Codex clearly states that if your website is served from example.com, for the sake of performance, you can have the cookies served from www.example.com by adding this to your ...
2
votes
1answer
113 views

Can WordPress store comment cookies on two different computers?

It's usual that WordPress stores comment author name and email in the user's browser cookies, so next time the visitor has to comment, they have their name and email already filled in automatically. ...
0
votes
2answers
294 views

How to set different cookies for logged in admin users and logged in non admin users?

I would like to identify admin users and non-admin (but logged in) users through cookies. I need this feature because I use Hyper Cache (which uses cookies to identify those who send pages in cache): ...
0
votes
1answer
321 views

Add session or cookie to remember last menu location

I have a site that is pretending to be three sites. This is done by a series of conditional statements and page templates to make it look like the user is on a different site depending on their menu ...
0
votes
1answer
75 views

region selection

I'm developing a website, where the visitor has to choose it's region Europe / Asia, according to this choice the menu should be different, (most pages are the same). When I would develop this in ...
3
votes
1answer
385 views

Authentication/API Questions

We are trying to use S2Member to manage our WP site and memberships for a Flash program that we are launching. We'd like to use S2Member to authenticate the user when they login and remain logged in. ...
0
votes
1answer
116 views

Lead Generation with Cookies in Wordpress

New Edit I would like to show the_content BEFORE the more tag when the cookie is not set and the_content AFTER the more tag when the cookie is set. I could not answer to my own question because ...
2
votes
3answers
544 views

Making a Custom Post type only visible to non-users via a specific link

I am working on creating a small web-app with wordpress as the framework. It allows you to input a customer and in turn sends an email to the customer with a link back to the website in order to ...
0
votes
1answer
40 views

Cookie Details Requested

We have Wordpress 3.4 installed and looking for details regarding functionalities of cookies created by wordpress. This information is needed so that we can align with EU cookie laws. So please ...
3
votes
2answers
184 views

WP_Http_Cookie destroys cookie value through urldecode()

Background: Working on a Widget that uses a remote API using wp_remote_post to log into the service, once logged in storing the cookies received for the second request to query data with ...
0
votes
1answer
712 views

Issues with set cookie

At first I had my setcookie() as: $school = "Some Value"; setcookie("default_school", $school, time()+3600); var_dump($_COOKIE); That didn't work, so I did some searching, and found that I probably ...
1
vote
0answers
121 views

Contact Form 7 - Show additional post content when a user enters their information [closed]

Is it possible to show a brief snippet of a post until someone submits a form using contact form 7, at which time a more detailed post is displayed automatically? Is it also possible to store a ...
1
vote
2answers
204 views

background/font size change and remember

I want to create font size and background change buttons, which i know how to do it. The problem is with remember it, so if user will go to a different page, background and font will stay the same. ...
2
votes
1answer
3k views

Exclude content from w3 total cache [on hold]

I use w3 total cache on a site I run which also now has to display a small popup at the bottom of the page to mention that the site uses cookies (thanks EU). The idea is that this only appears the ...
0
votes
2answers
398 views

WordPress Post Voting - Vote once per IP on entire site

I've been researching this for a few days now and found many voting plugins - unfortunately none of them do exactly what I need, so I am trying to hack some functions/scripts that I've found by ...
2
votes
1answer
295 views

2 wordpress blogs with 1 users table and 1 login

I have been trying to achieve that and I did without the 1 login part I fallowed this post/tutorial , but no matter what I do I can not get it to login ones for both websites. My set up is ...
0
votes
2answers
175 views

Serving wp-includes (front-end) javascript from a different domain?

The WordPress Codex points to an extremely simple way to change the URL of the wp-content directory, which is, adding this in wp-config.php: define( 'WP_CONTENT_URL', ...
0
votes
1answer
86 views

Accept or deny cookies - how to?

As far as cookies privacy policy has been change, i need to make a script which allow to accept (or not) cookies by user for this domain (website) only. Is there a way to do this for one website only. ...
0
votes
1answer
517 views

Do I use cookies?

I have made website in wordpress, and now client wants to know do this website use cookies? I dont know too much about it becouse i never use it, but i need to be sure. If I make websites i use ...
0
votes
1answer
1k views

Getting a person's username from a wordpress cookie

My friend has a code that will allow users to receive a special key to gain access into into the closed/open beta event for any game they select. When a person is logged in, they can click on a link ...
3
votes
2answers
348 views

Allow guests to save favourite pages?

We're creating a site where we want guest users to add pages to a favourites list (post IDs), so they can print or email their selection if they want. What would the best way be to do this in ...
2
votes
1answer
2k views

Worpdress PHPSESSID / EU law

WordPress is installing a PHPSESSID cookie as soon as someone lands on my site. Under new EU law if its non-essential i have to block it so that a user can opt-in. But if it is essential its ok as ...
1
vote
1answer
2k views

Set a cookie in WordPress, using a select form and Jquery

Hi Guys and thank you in advance for giving me some attention with this. I have this code in wordpress that I just can't get right. I have the US states in a drop-down form. When the user chooses an ...
1
vote
1answer
215 views

Why is my cookie not unsetting upon logout? [closed]

if (is_user_logged_in()){ if(!isset($_COOKIE['alertuser'])){ // set cookie $timer = time()+86400; setcookie('alertuser', '1' $timer); // show alert ...
0
votes
2answers
227 views

How to Collect Keyword and Search Engine Data on Webforms?

We have a contact form using Contact Form 7 on our wordpress site. We would like to be able to attach any information about where the user came from: keyword search is the #1 item of interest. We ...
1
vote
1answer
194 views

Wordpress cookies

I am trying to set a cookie on click via setcookie('mycookie', 1, time()+60*60*24; but I can not seem to get it working . If i click the button - when I check my cookies, it is not there .
-2
votes
1answer
927 views

Is it possible to tell if a user is logged into Wordpress from looking at the cookies which are set?

Is it possible to tell if a user is logged into Wordpress from looking at the cookies which are set on a site? If not, how could I add hooks to the login success and logout actions and set my own ...
0
votes
1answer
206 views

Trying to set a cookie based on $_POST parameter

I'm doing a bit of language detection that first checks the $_SERVER['HTTP_ACCEPT_LANGUAGE']. If the user wants to override the choice of language, there's a select list, where they can choose ...
4
votes
1answer
319 views

How to detect a user that is not logged in

Is there an easy way to see if a user - someone how has logged in in the past but is not currently logged in - is visiting my site? I was thinking that checking if $COOKIE[TEST_COOKIE] is set, but I ...
2
votes
1answer
844 views

Set cookie then immediantly refresh the page

I wrote a small WordPress plugin (mobileesp-for-wordpress) that will redirect mobile users to the mobile site. It's based on mobileesp. The plugin itself works fine the problem is I added an option ...
0
votes
2answers
925 views

How to force “remember me” users to login again?

My question is how to force the users that are auto-logged in because they previously checked "remember me" to log in again? It may be something with cookies, but is there anything I can ...
0
votes
2answers
171 views

Cookies in template

I need to show some part of the page only once, based on cookies. The main problem that I can set cookies only in plugin, hooking init action. I've read 20 pages of google, this site, asked 2 forums, ...
1
vote
2answers
148 views

How does Wordpress remember which editor is being used?

Hey so I am trying to determine how Wordpress remembers which editor is being used for a particular post (HTML or Visual Editor (tinyMCE)). When you write a post, and then come back, it goes to the ...
0
votes
1answer
1k views

Why doesn't the “Remember Me” checkbox work for me on a live website? Only works on a local server environment

If I check "Remember Me", and then log out, my login and password are not remembered. I've tested this on many WordPress sites running WP 3.2.1 on a server here in NZ and also on a completely ...
2
votes
2answers
1k views

Wordpress Redirect based on the prescence of a cookie

I have a tricky situation.... I'd like to check for a cookie. If it doesn't exist then then redirect to an internal wordpress page, and set a cookie. And then carry on browsing the site. But i get ...