Forum Replies Created

Viewing 15 replies - 136 through 150 (of 3,259 total)
  • The cPanel file manager search option I am familiar with (the one on the right of a bar across the top of the file view display) does a search for files by name. It would be surprising indeed if you had a file with “single_add_to_cart_button” in its name.
    Under my linux based system (Ubuntu) I use a command line program called “grep” to do a recursive search on text file contents. Not sure how I would manage without it.
    Here is a way to do this:
    https://webmasters.stackexchange.com/questions/12333/how-to-grep-or-find-on-cpanel
    another option is to login to your site using SSH, It has to be specifically enabled by your hosting, I have never done this.
    Another way to run command line programs on your website is to use the CRON feature, create a task a few minutes into the future and soon enough the script results will be emailed to you, then disable the cron task.

    • This reply was modified 5 years, 2 months ago by RossMitchell.

    Could the create new users and related problems go back to the security breach ?

    If nothing works the website, including the custom theme, can be installed anew in a fresh WordPress installation I guess. But that would be a lot of work obviously, especially to port all content over.

    Of course the easiest way to restore the content is to restore a database backup. EXCEPT that the backup includes the glitched database field settings. Do you have a backup pre security breach ? Or is its content out of date ?
    If you look at the .SQL database backup you will see that it creates each table then loads its content, only after doing all this does it create the database keys and set the field options such as auto increment. So I would try and make a restore database load that has the table creating and data load from the recent backup, and add the tail of the ancient backup or from the tail of the empty WP with all plugins backup.

    Suggest that you create a staging website on a subdomain, same WP version as your live site, take a database backup of the empty website. Install your theme and plugins, activate plugins. Take another database backup.
    Take a database backup of your live site.

    You now have several database backups, make copies of them and strip out the table data contents, just leaving the descriptions of the database tables.
    Compare the different database descriptions, this will tell you which settings etc are missing from your live site. Fix it.

    As to how this has happened, this is a riddle. Are you sure that your web hosting is secure ? Suggest changing ALL your passwords: Hosting, website database, website admin.

    Suggest that you use the support forum specific to your theme.
    Otherwise use your browser inspector to find the elements that cause these problems, then use the customizer > Additional CSS feature to add modif your CSS.

    This text is very likely being generated by your theme. Suggest that you use your browser inspector to find the html/css context of this button, searching your theme for the specific classes etc used will get you to the code that generates the button and its text.
    Myself I keep notes in each website project folder so that I can quickly revisit the odd changes like these. It is a difficulty inherent to the WordPress system that odd details like this can get hidden away and be managed in many different locations.

    This is certainly possible to do. I have made systems that do this.

    I would add a new table to the WordPress database, this will be completely used by your own code, the rest of WordPress will know nothing about it. This way you can use the same $wpdb variable to access your table as used by the rest of WordPress.

    I found studying this plugin very informative in many ways.
    https://wordpress.org/plugins/wp-csv-to-database/
    Author: Ruhul Amin

    Be sure to use “prepare” to safely incorporate the user input field into your SQL query.

    There are two different ways to incorporate your code into your website:
    – In your theme as custom page templates.
    – Create a plugin, have it register shortcodes that your search page uses to activate your code.

    You can write regex expressions that could do this.
    Then you could use filters.
    Suggest that you look into the PHP regex functions.

    Suggest that for the big plugin you:
    – download the plugin ZIP file to your computer
    – extract the files on your computer
    – rename the local plugin folder
    – using FILEZILLA upload the plugins files to your server using FTP
    – using FILEZILLA rename the old plugin directory and rename the newly uploaded plugin to the expected name.

    Firstly it looks like apache is not configured to be able to update your WordPress website files because they are in “/usr/share/wordpress” this would usually be where binaries live. Files that applications store data in are conventionally in the “/var” tree. The point here is that in addition to the file system permissions, apache has an additional permissions layer, this is good.
    Myself since I am developing my websites I put these files in my own files under a “web” subfolder, to do this I have this block at the top of my apache site config data (in ubuntu this is: /etc/apache2/sites-enabled/001-local )

    <Directory /home/ross/web>
     Options Indexes FollowSymLinks
     AllowOverride All
     Require all granted
    </Directory>

    Secondly it looks like some of your files are in the wrong places, like
    “wp-includes/PHPMailer/SMTP.php”
    I would expect to see that in with the plugins.

    Thirdly, I find it much easier to manage my files, media, themes, plugins etc, all using my file system file manager, instead of needing FTP or updates.

    What you need to do is use your browser inspector to see how your web pages are being structured and how the content width is being set by the CSS. Once you have done this you can change these settings using either the customizer > Additional CSS, or in a child theme.

    Your answer depends upon the details of your theme.
    Look at your theme files and see how it assembles your website’s pages, in your theme folder you will likely have a file “header.php”, it will produce your “<head>” tag, and then call a hook function such as “afterhead();” (or similar), or maybe just “wp_head();”. See how it is defined, it will tell you how to add a function to this hook. Similarly after the “<body>” tag it calls “wp_body_open();”.
    In each case find the hook that is invoked in that context. Now add functions to these hooks, could be done in a plugin, but more likely in the theme’s “functions.php” file, to do this properly you need to be working in a child theme, details here:
    creating a child theme http://codex.wordpress.org/Child_Themes
    if this does not suit you then this may help:
    https://github.com/woothemes/theme-customisations

    I have given specifics for the twentynineteen theme, the specifics may vary.

    Two ways, either of them will fix your problem, choose the one you are most comfortable with:
    – If you have a database backup just restore it.
    – Make the change in the database, access phpmyadmin, browse to the “_options” table, change the entries beside “home” and “siteurl”
    – You can just edit wp-config.php, normally people use either FTP or your hosting management login, add these two lines to your wp-config.php file.

    define('WP_HOME','http://yourdomain.com');
    define('WP_SITEURL','http://yourdomain.com');
    
    define('WP_HOME','http://example.com');
    define('WP_SITEURL','http://example.com');

    Then you will be able to login.
    Then you will be able to restore your settings in the database.
    Then remove the two extra lines from your wp-config.php

    more details are here:
    http://codex.wordpress.org/Changing_The_Site_URL

    • This reply was modified 5 years, 3 months ago by RossMitchell.

    Suggest that you look at the website hosting error logs.
    Maybe enable debugging.

    Are you sure that the database user you created has ALL capabilities over the database ?

    On my Ubuntu systems I always just do:

    sudo apt-get  install lamp-server^
    sudo apt-get  install phpmyadmin

    Though the most recent version I have done this on is 18.04
    NOTE that the trailing “^” is important!
    This will get a coherent set of apache2 + PHP + mySQL loaded and cooperating.
    You will be asked for a ROOT mySQL password during the install, be sure to record it.

    You will need the IP address of your ubuntu server, say it is: “192.168.A.B”, find out what it is and adjust my instructions.

    I then enable apache’s mod rewrite in a terminal with:
    sudo a2enmod rewrite
    I do my website development in sub directories of “/home/ross/web/” so
    at top of configuration file: “/etc/apache2/sites-enabled/001-local” I add

    <Directory /home/ross/web>
     Options Indexes FollowSymLinks
     AllowOverride All
     Require all granted
    </Directory>

    Then I configure each website + URL like:
    in file: “/etc/apache2/sites-enabled/001-local” (or similar)

    <VirtualHost *:80>
    DocumentRoot /home/ross/web/wpB
    ServerName wpB.local
    ServerAlias www.wpB.local
    </VirtualHost>

    Add add these line to file: “/etc/hosts”

    127.0.0.1	wpB.local
    127.0.0.1	www.wpB.local

    And on your windows PC these become:

    192.168.A.B	wpB.local
    192.168.A.B	www.wpB.local

    Good luck.

    I speculate that losing and then reconnecting your internet connection somehow disrupted the “session” you had established between your browser and webserver.

    Suggest that you logout and then login again, maybe you have already done this in which case I have no idea.

Viewing 15 replies - 136 through 150 (of 3,259 total)