Articles of ip

Restricting user login by IP address

I have a website that is login required in order for users to view the website. I have set up one user for all internal members to use to view the website, however i want to limit just that user to our specific IP address. I can see you can limit access site-wide to an […]

Is it possible to get the currently logged in admin's IP?

Given a wordpress (3.4.x) install that only has 1 admin, how would I grab, from within a plugin, the IP of the currently logged in admin, if there is an admin logged in? In other words: I need to obtain the IP of the admin, IF there is admin is logged in, and use this […]

Display posts if specific country

I’m running a simple query that displays some posts within a custom post type. Via each post within that post type, I’ve added an ACF True / False checkbox. If the checkbox is ticked, I’d like that post to only appear if you’re within the USA. Here’s what I have so far: <?php // Begin […]

Limit access to wp_admin

I’m attempting to limit access to wp_admin by IP address but I still have a few that are getting through. I have an htaccess file in my wp_admin folder with the following: # Block access to wp-admin. order deny,allow allow from x.x.x.x deny from all I’ve tested the implementation by trying to access the login […]

Is it possible to store visitors IPs in wp_postmeta table?

Or in any of the other 11 WordPress tables. I also need to store: submission date, name, contact number in the same table. What approach would be best? A custom table or using a standard table?

Broken CSS after changing the site URL

I have a self-hosted WordPress blog on my home server. Previously I accessed it directly via its original IP address taken from DHCP, but now I have configured a static IP address for it. The problem is that now all the CSS is broken. I have updated my wp-config.php file adding the following two lines: […]

How to set ipv6 address as siteurl?

I have try to set ipv6 ip address as home and site url, but it seems not work perfectly. From there: http://[2001:da8:d800:71::250]/wordpress/ (if you view the source) we see that some url, such as pingback (line 16) where correct, but others, such as rss (line 20) were lost [ and ], how to fix this? […]

Check if a user already voted

I’m writing a WordPress poll system. I need to check if a user already voted, show him/her a message. But i dont know exactly how can i do that! One of my solutions is that to creating a table (named wp_voters) and entering each user’s ip and poll id. $user_ip = $_SERVER[‘REMOTE_ADDR’]; But it doesn’t […]

How do I turn off wordpress comments ability to capture a users ip address?

Going through the comments table on my wordpress site, I noticed that wordpress is storing the ip address of everyone who makes a comment on my site. How do I remove this functionality? I’m not just talking about the display of the ip in the template, I mean I don’t want wordpress to capture it […]

Relative or dynamic site url possible?

I have a local Xampp wordpress installation that I am using as sort of an intranet with some people I work with. I require them to be able to access it on our LAN router — I found that I needed to change the site url and links from http://localhost:8080 to my IP http://192.168.x.xx:8080 for […]