w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
getting deleted users in wordpress
The user_status column is deprecated and has been for a while. I just created and deleted a user, and it was completely removed from the database. Are you sure the database contains deleted users?

Categories : Wordpress

ACCESS DENIED to mysql DB with PHP but can login with phpmyadmin and on the command line
The user you're going to use with your scripting should have both the "@localhost" and "'@%'" - Have a peek at the man. http://dev.mysql.com/doc/refman/5.1/en/adding-users.html This gave me a headache once.

Categories : PHP

Wordpress: How do I make a login system with users having their own profile and be able to send messages to each other?
Most of that is straight out of the box with Wordpress. Care to expand a little bit and we can perhaps suggest some plugins or ways to extend? For example, are you trying to run a facebook style social site, shopping cart, reddit etc.. To clarify further: User can register and login Out of the box with Wordpress. To hide the fact that the system is running wordpress have a look at the front end logins which integrate directly with the theme you are currently using. Have a look at Theme My Login Users have own profile (profile picture and short info) Again, out of the box. Set "Anyone can register" to true on the Settings page of wp-admin and when a user signs up they'll be asked to fire in profile information (works well with Theme My Login). Users can send messages to eac

Categories : Wordpress

Unable to login to MYSQL getting error ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
It seems like a permission issue, try disabling selinuza by using setenforce 0, then restart the mysql service, also check if mysql has the right permissions on the mounted device (assuming you mounted as root or a sudo user that mysql cannot access)

Categories : Mysql

MySQL Query to Bulk Delete Spam Wordpress Users
You can use a INNER JOIN when using DELETE in MySQL. DELETE FROM wp_users INNER JOIN wp_usermeta ON wp_users.ID = wp_usermeta.user_id WHERE wp_users.user_email LIKE "%@hotmail%" AND [etc, etc.] This solution gives you two (or maybe more ;-)) problems: 1) you can't reassign posts and links (if you want) and 2) you have to deal with JSON values in MySQL. A better way is to use WordPress functions for the job. You can use get_users to search for users and wp_delete_user to delete the user. <?php $args = array( 'blog_id' => $GLOBALS['blog_id'], 'role' => 'subscriber', 'search' => '*@hotmail.com' ); $blogusers = get_users($args); foreach ($blogusers as $user) { wp_delete_user( $user->ID, $reassign ); } ?> Please read

Categories : Mysql

Is there any way to find who is deleted database from Phpmyadmin which is hosted on linux server
I guess you just have to check your log file. Here how to log all queries in mysql Log all queries in mysql

Categories : Mysql

Login system using physical postgres users not "logical" users
To achieve your goal all inserts, updates and deletes, need to leave a trail that is difficult, if not impossible for a standard user to change. you can create: 1) Two schemas: one for common tables, one for security stuff like login/pass(hash) table, user session log, change log table, etc. 2) Two users: one common user, that can only use dml on common schema (no ddl), one superuser. 3) Login function that will check provided user/pass against login/pass table and log successful/failed attempts into user session log (you need SECURITY DEFINER function) 4) Set of audit triggers on common schema tables that will check the user privileges and log any changes, made by the user (SECURITY DEFINER functions here too).

Categories : Security

PhpMyAdmin login screen
Go to WAMP folder. And search config.inc.php file. When you open that file, the file will have something like this: <?php /* Servers configuration */ $i = 0; /* Server: localhost [1] */ $i++; $cfg['Servers'][$i]['verbose'] = 'localhost'; $cfg['Servers'][$i]['host'] = 'localhost'; $cfg['Servers'][$i]['port'] = ''; $cfg['Servers'][$i]['socket'] = ''; $cfg['Servers'][$i]['connect_type'] = 'tcp'; $cfg['Servers'][$i]['extension'] = 'mysqli'; $cfg['Servers'][$i]['auth_type'] = 'cookie'; $cfg['Servers'][$i]['user'] = 'root'; $cfg['Servers'][$i]['password'] = ''; $cfg['Servers'][$i]['AllowNoPassword'] = true; /* End of servers configuration */ $cfg['DefaultLang'] = 'en-utf-8'; $cfg['ServerDefault'] = 1; $cfg['UploadDir'] = ''; $cfg['SaveDir'] = ''; ?> Search for this line: $cfg['

Categories : Mysql

php preg_replace find — replace with —
You should not use preg_replace to replace a constant string. Just use str_replace instead. $description = str_replace("&mdash;","—", $description);

Categories : PHP

Wampp - I cannot login to phpmyadmin after new installation #2002
Run cmd to get a window Change directory to where mysql console is e.g. C:wampinmysqlmysql5.1.36in> Run the console with mysql password isn't needed on the default installation and you'll be treated as root you should get a prompt to enter your password. Use the one you put in your config file. More info here MySQL and WAMP PS MysqlD is the mysql daemon, think service in windows terms. mysql and mysqladmin are the console apps to set up and control it.

Categories : PHP

Configure phpMyAdmin with username and password not allows to login
There was a conflict: the phpMyAdmin configuration that says to not allow login without a password ($cfg['Servers'][$i]['AllowNoPassword']= FALSE;), but my mysql user (root) had no password so I couldn't login! So as mentioned in one of the answers here I had to set password to the root user by: # mysqladmin -u root password your-password Then restart servers and login again

Categories : Mysql

how to integrate wordpress users with vbulletin users
You can give a try to obscureclouddon's mod, as an alternative to vbSSO. (an other link here) It seems to be a good choice, since it has features you need : WordPress->vB features: *Registration sync – new users created on WP are automatically created on vB vBulletin ->Wordpress features NEW *Registration sync – new users created on vB are automatically created on WP The bad things are : this modification is in beta stage free version has limited features, the pro version is, IMHO, expensive... (but it could worth the cost..)

Categories : PHP

Getting deleted users by lastknownparent in windows active directory using c#
Maybe I'm a little bit late but I hope this answer will help. Just replace ADEL with \0ADEL in your LDAP query. By the way, this rule applies to every attribute with dn syntax.

Categories : C#

How can I count actual number of followers when if some users are deleted?
At the first: are you using latest version of acts_as_follower gem? I take look at code and here is relation with :dependent => :destroy: has_many :followings, :as => :followable, :dependent => :destroy, :class_name => 'Follow' So, it should not be a problem, after destroying user - all following relations will be destroyed too. If it not - maybe you are using paranoia gem or something like this? Please, show me your Gemfile. Thanks! what if I'm not doing that? How can I still count with avoiding un-existing user? If you are not do that, you can do something like this: @follower_users_count = user.followers(order: 'updated_at DESC').select{|f| f.user.present? }.count Also, you can look at gem code and try to join users table to sql request and check for the existe

Categories : Ruby On Rails

Deleted user attempts to login
You don't need to delete from the cookie. You are using find_by_auth_token! which will raise an exception if the user cannot be found. If you use find_by_auth_token without an exclamation mark then the call will return nil if no user can be found for the auth token and @current_user will be nil.

Categories : Ruby On Rails

how to keep the user login for all pages in wordpress custom login function?
You can use the wp signon function: Function Reference/wp signon as you can see here: <?php wp_signon( $credentials, $secure_cookie ) ?> it gets and array ($credentials) and a boolean (which is optional). here you can see a sample code it's use: $creds = array(); $creds['user_login'] = 'username'; $creds['user_password'] = 'password'; $creds['remember'] = true; $user = wp_signon( $creds, false ); if ( is_wp_error($user) ) echo $user->get_error_message(); this function is a core wp function, means that which means that when it's used, it will do everything the wordpress need it to do for it to work as it should. next, you need to use WordPress Cookies. in your case i have seen you used: Function Reference/wp set auth cookie which is taking these parameters: <?ph

Categories : Wordpress

wordpress redirect loop on the login page (wp-login.php)
You can try these steps. Log in to wordpress database using phpmyadmin. go to wp_options table and go to page two. Remove active plugins. If you have a backup of the old database paste the plugins back in. OR 1) Backup your .htaccess file on your hard drive 2) Delete the .htaccess file from the root of your server 3) Go to your blog’s admin panel and log-in 4) On the left sidebar, go to Settings –> General and changes your WordPress Address and Blog Address to include www (so it should be http://www.domainname.com instead of http://domainname.com). 5) Save Settings 6)Take your .htaccess backup and reupload it to the root of your server/directory

Categories : Wordpress

Not able to login in facebook with facebook sdk 3.0 loginbutton button using other users, though it is working with developers login credentials
In your facebook's dev account check that your app is set to sandbox mode, so only developer accounts could get access token from app's ID, once you disable sandbox mode, your app will go live and you can log in with any facebook id.

Categories : Android

Create a wordpress login form to a non-wordpress website
You can do this in 2 ways. Cookies Sessions After your login is validated you store the information in an cookie/session, you send the users to your wordpress website. And the login page, checks if the desired session/cookie is available and if yes you skip the login fase.

Categories : PHP

Do Removed / Deleted WordPress Widgets Are Lost Forever?
It depends on the widget: the widget developer decides where and how to store the widget data and if that data has revisions or not. At this point you have the fallowing options: 1) access your database and have a look in the "_options" table for for the option_name %LIKE% widget -> it will show you all the data you have saved related to that widget, if you don't find what you are looking for: 2) check the php code of the widget to see if you can find where it saves the data and if it has revisions. Your best luck is to have the data in the "_options" table and if you have backup of the table you can extract the data from there.

Categories : Mysql

Custom login instead of wordpress login
Honest question: why? You can customize the WP login process quite a bit, and it handles much of the heavy lifting for you. Here's a toolkit I built for custom login pages and more: http://cferdinandi.github.io/web-app-starter-kit/

Categories : Wordpress

mysql foreign key using phpmyadmin
order is a MySQL reserved word (it's used in ORDER BY clauses), you have to enclose it in backticks if you want to use it as the name of a table or column. CREATE TABLE `order` ( Orderid INT NOT NULL, cost INT, CustId INT NOT NULL, PRIMARY KEY(Orderid), INDEX (CustId), FOREIGN KEY (CustId) REFERENCES customer (CustId) ); You'll have to remember to put it in backticks whenever you reference it in a query. You'll save yourself lots of trouble if you simply choose a different name for the table.

Categories : Mysql

How to create a MySQL trigger in phpmyadmin
This is caused by not changing the delimiters temporarily as you did via CLI. Try either: CREATE TRIGGER before_insert_money BEFORE INSERT ON money FOR EACH ROW UPDATE accounts SET balance=10.0; or delimiter // CREATE TRIGGER before_insert_money BEFORE INSERT ON money FOR EACH ROW BEGIN UPDATE accounts SET balance=10.0; END; // delimiter ; See: This question and this question.

Categories : Mysql

Do the indexes from the phpmyadmin MySQL need to be the same in Sphinx
No. You setup sphinx to index the column(s) you need to be able to search. They dont need to match mysql indexes at all. But if you recreating a search that used to use the mysql full-text indexes, then you would create the sphinx index on the same column(s) plus any additional columns you need to be able to filter, group or sort by.

Categories : Mysql

Insert if not exist (in mysql via phpmyadmin)
You can do something like : INSERT INTO mytable ( key, attribute ) SELECT 1, 'aaa' FROM mytable WHERE NOT EXISTS ( SELECT 0 FROM mytable WHERE attribute = 'aaa' ) ;

Categories : Mysql

mysql collation is fine for phpmyadmin but not for sql
First of all: You are barking up the wrong tree. Your problem is not collation (or you have not yet found out so), but encoding. in the tables on your connection I recommend you start debugging by putting a query like SET NAMES 'UTF8' at the start of your PHP scripts. Quite likely, this will make the immediate problem "go away", giving you a foot in the door for a more permanent fix.

Categories : PHP

Creating foreign key in phpmyadmin mysql
Data is not inserted in the other table "voted_ip" on insertion in "comment" by itself you have to add it explicitly this constraints are just for checking not for adding data in other table automatically.

Categories : PHP

mySQL inserts failing in PHP but not in phpmyadmin
This is not a query you are running but set of queries. So, just run them one by one, not in one statement. Also, you idea of using mysqli_real_escape_string is quite wrong. This function have to be used to escape special characters in string literals only, not to process whole query. Anyway, you have to use prepared statements instead. As its usage is quite complex with raw mysqi, consider to use PDO instead.

Categories : PHP

MySQL INSERT query works in Phpmyadmin but not in PHP
When trying to debug code, it is helpful to use mysql_error()/mysqli_error($link) in your die() rather than a generic string - die('Could not access table'). Also, the order of query/link in mysql/mysqli is not the same mysql_query is mysql_query(query,link), so your code should be $query = mysql_query($rawquery,$link) or die(mysql_error()); while mysqli_query is mysqli_query(link, query), so your code should be $query = mysqli_query($link, $rawquery) or die(mysqli_error($link));

Categories : PHP

MySql #1243 error while executing it through phpMyAdmin
That is because the PMA doesn't use the same mysql session to execute the queries that's why you receive the error. But if you were to execute this in a script using the same mysql function it should work.

Categories : PHP

function does not exist .. in phpMyAdmin mysql Query
Ok, I created a table Date on one of my phpmyadmin databases, just to see how this query works. My table has 2 columns, date_of_birth and date_of_death, both of type date. I inserted some 5 or 6 tuples. And after that typed in this query: SELECT DATEDIFF(date_of_birth, date_of_death) FROM Date; It worked just fine. Gave me 7,53, 365, 733...ergo, the correct results, without any error. I think there is something wrong in your database.

Categories : Mysql

How to import leading zeros in mysql db from phpmyadmin by ods
I have found one ugly solution: Insert ' in front of all ID: '01344, '01345 ... save and import ods. Delete ' from db with: UPDATE items SET ID = SUBSTR(ID, 2); I hope there is better solution! If there is, please share it :)

Categories : Mysql

MySQL sort by a column by default in phpMyAdmin
There is no "default" ordering of rows. If you want a query to return rows in a particular order, then you must use an order by clause. You cannot even depend on rows being returned by the primary key order. In fact, with updates/deletes/inserts on the table, this will often not be true. If you want a query to return rows in a particular order, then you must use an order by clause (I realize I repeated that). The only exception is that MySQL (in violation of the standard) guarantees the ordering of results when using group by.

Categories : Mysql

mysql query error in PHP but working in phpmyadmin
You have to use transactions to perform several commands in MySQL. You create a varible first and then execute another command. Using just single function mysqli_query you can perform only one command and commands are separated by ;. When you paste the code into PHPMyAdmin, it will work though as it is still supposed to be a transaction. You can read more about transactions.

Categories : PHP

Delete all records in a table of MYSQL in phpMyAdmin
Use this query: DELETE FROM tableName; Note: To delete some specific record you can give the condition in where clause in the query also. OR you can use this query also: truncate tableName; Also remember that you should not have any relationship with other table. If there will be any foreign key constraint in the table then those record will not be deleted and will give the error.

Categories : Mysql

Constant #1064 error on everything I do in mySQL through phpMyAdmin
you have missed the name of your table in all queries SELECT MAX( version ) FROM your_table ^^-----your_table_here and you dont have to include database or table in where clause . you need to learn the basics of select query.

Categories : Mysql

Mysql inserts blank field from php script, but not in phpmyadmin?
firs thing first $_POST('name'); is nothing $_POST['name']; is right. Now answer to your question use following query. $sql = "INSERT INTO `Prototype`.`Version` (`version_name`, `version_status`, `created_date`, `created_by`) VALUES ('A', 'A', CURRENT_TIMESTAMP, NULL)"; I have also checked it on my own table made from structure provided by you. it's query is given below. CREATE TABLE `proto` (  `version_id` int(3) NOT NULL AUTO_INCREMENT,  `version_name` varchar(45) NOT NULL,  `version_status` varchar(45) NOT NULL,  `created_date` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,  `created_by` varchar(45) DEFAULT NULL,  PRIMARY KEY (`version_id`)) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=latin1 Below code is for you to submit it via php. $options = ar

Categories : PHP

mysql phpmyadmin User Input COMPARE database
I would use a different approach and do the search in your SQL-query. SQL is better (and performs better) on that kind of searches. You won't need a while loop for this query: SELECT * FROM users WHERE username = '<input username here>' OR email = '<input email here>' If you get a result, it means that either the username or the e-mailaddress is already registered. Use an if-statement to check whether or not it's the username or the e-mailaddress. Please, don't use mysql_* functions in new code. They are no longer maintained and are officially deprecated. See the red box? Learn about prepared statements instead, and use PDO or MySQLi - this article will help you decide which. If you choose PDO, here is a good tutorial. EDIT: The full PHP-code would be something like

Categories : PHP

MYSQL query running at phpmyadmin but not through mysql_query in ActiveCollab
I found the issue. It is DB::beginWork('Deleting recurring profile from Credit Card Vault @ ' . __CLASS__); which is called just before running DB::execute command. As this operation is terminated (with an exit()) before the system could mark transaction 'completed'. It resulted into making the system to 'rollback' the recent DB changes it's own methods/functions might have done to the system. It is still a mystery that why UPDATE worked on some tables and not on some though. Thanks for looking at it anyways!

Categories : Mysql

phpmyadmin mysql INSERT statement syntax error
The string value you're inserting into the email filed needs to be quoted. Also, the names of the table and columns shouldn't be quoted. The query should look like this: INSERT INTO members (username, password, fname, email, contactnum) VALUES (2, 2, 2, 'have@gmail.com', 1) Note that the first three fields you're changing are declared as varchar, so you should be inserting strings into them as well. The reason you're not getting errors for trying to insert integers into varchar fields is that in some cases the wrong data type can be automatically converted. I think it's better practice not to rely on implicit type conversions, to avoid errors and unexpected results, so the query really should be written this way: INSERT INTO members (username, password, fname, email, contactnum) VALUE

Categories : SQL



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.