Madalin Ignisca
Forum Replies Created
-
Forum: Plugins
In reply to: [Autoptimize] test for constantsGood to know you’re using Github. I’ll bug with PR from now on…
Forum: Plugins
In reply to: [Autoptimize] test for constantsI think that it would be a best practice not to set Constants that may impact other plugins or custom installations.
Usually, and this is not specific to WordPress only, Constants should only be set by the core and in a config file, in WordPress in wp-config.php.
Other constants that would be related only to specific plugins/themes, could be used, but offer a way to change them in case that the user needs to do so, so again, a test if it is set should be done. The value of a constant should offer first the possibility to be set through System Variables.
Best would be to start with a check on environment:
if($constant = getenv('MY_AWESOME_CONSTANT') && getenv('MY_AWESOME_CONSTANT') !== 'my_awesome_value' && ! defined('MY_AWESOME_CONSTANT)) { define('MY_AWESOME_CONSTANT', 'my_awesome_value'); } else { add_action( 'admin_notices', function() { echo '<div class="warning">Plugin X can't work with <strong>MY_AWESOME_CONSTANT</strong> set to a different value then <em>my_awesome_value</em><br />Please refer to <a href="http://address_to_issue">KB_X</a> to find a solution</div>'; }); }If the functionality depends on an exact value of a Constant, then instead of throwing an error or work strange, it should offer a way to inform the user the situation and offer a way of solutioning it.
Setting of Constants common as usage it is not a best practice when delivering modules like WordPress plugins.
In my case, I’m working on a SaaS application that offers WordPress as a service, and all possible WordPress Core Constants and many other settings are controlled by the management application responsible of deploying and managing all WordPress installations.
In this case of the Caching and Css/Js assets management, those Constants are set depending on certain situations the users are using their websites (for example for Admins and Roles that are set for testing purposes.
For the production instances, I am setting those Constants to true because of some other custom integration I have done, so I had to do the tests in your plugin, so I don’t get megabytes of logs full of the warnings 😉
I came up on your plugin, as it is doing it’s job better then any other plugins we have tested.
Keep up the good work with it!
Regards,
MadalinForum: Plugins
In reply to: [W3 Total Cache] Memcached or APCI’d recommend you start with APC (APCU in php 5.4+ if you use Opcache as well).
Switch to Memcache when you will need to deploy the site on multiple servers; that would be a scenario of hundreds of pageviews at the same time.
APC(U) would be even faster on a single server as you access everything internal PHP – APC, as on PHP – Memcache you have a special network layer, and you have also the network delay as well (if you have separate servers).
Ironic, but let me quote:
I woke up to this weird error that simultaneously knocked out all my wordpress sites (even across different hosts).
You’re doing updates without proper testing before on production?
Forum: Fixing WordPress
In reply to: Can't upload images after new installYou’re welcome.
Forum: Fixing WordPress
In reply to: Can't upload images after new installAdvise:
I know that many people still use PHP 5.2 or PHP 5.3 but I strongly advise everybody to use an officially supported PHP.
WordPress runs on PHP 5.6, 5.5 and 5.4 very well, versions that are supported by the PHP community and from experience, WordPress runs way more faster on PHP 5.6 and 5.5.
No. Chrome up to date, all WP sites with everything updated and it doesn’t happens.
Hi there.
Disable your BeTheme for a few minutes (normally it should not harm your website).
Try to activate your VC plugin.
Still issues? Go to ThemeForest, redownload the hole zip of Betheme. Unpack, delete in your FTP all BeTheme and VC directories, upload fresh.
I know the theme and the plugin as I’m using them for several clients. They don’t have problems with missing files.
Still problems? Try on a fresh installation of WordPress, first put VC, then BeTheme. If you still have problems, then you should request support from your host as some things might be from their side (strange PHP configs?).
Forum: Fixing WordPress
In reply to: Can't upload images after new installThe USER to use with 75X on directories and 64X on files must be the same as the user used for the PHP process.
Normal webhosters guarantee that.
If your USER is not the same with the one that PHP runs, then you are forced to do 777 on directories in wp-content/uploads (you don’t need to all other WordPress’s directories/files).
If you could provide more details on how you host it, I can provide you exact information on how some stuff related to Nginx or Apache with PHP should/must be.
Forum: Installing WordPress
In reply to: Instalation error@jfantico, could you be more specific? I see it’s working.
Forum: Installing WordPress
In reply to: WordPress installation on Debian 7.8 WheezyHello.
Doing it from the distribution’s packages, you won’t be able to update from within WordPress.
As you installed WordPress using the package manager in Debian, now you know that you have the hole needed LAMP pack to run WordPress.
Uninstall WordPress (apt-get purge wordpress) and install it manually.
Make sure after you install it to change the owner of the hole installation (/var/www in case you are making it the only site on your server) to “www-data” (same for group).
“sudo chown -R www-data:www-data /var/www”
(That is as you installed previous WordPress from the Debian repo and PHP will run as mod_php under Apache.
Let us know if it worked, if not, I could offer you more advanced help for running WordPress (multiple installations) under Debian/Ubuntu servers (other distributions as well).
Forum: Installing WordPress
In reply to: Instalation errorHi @derekdonovan.
As it doesn’t gives you an error of bad credentials or database not found, that error is when it doesn’t finds the SQL server.
Look in Mamp, check if your MySQL runs on a certain port. The free version of Mamp has different ports out of the box for both Apache and MySQL.
By default MySQL is on port 8889.
In your WP install process, for the database address fill in “localhost:8889” instead of just “localhost”.
Now it will find the database.
Let us know if it worked.
Forum: Fixing WordPress
In reply to: I've lost my whole siteHi @sallison727.
Make sure you have a backup of the Uploads folder inside of wp-content as well.
If you could check in the previous database if you had a custom prefix, will help you in one of the next steps.
- Do a fresh install of WordPress. (Use the custom prefix on the database if you had!)
- Now, drop all tables in the fresh database and replace it with the backup one
- Sync your Uploads folder also
Now you should have your website back.
Hi.
The latest stable version isn’t working with recent WordPress/BuddyPress.
For the moment, only WordPress 3.5 / BuddyPress 1.6 would do. With a bit of work, you could use that and make your installation secured.
I got interest in Courseware a few months ago and decided to rewrite it for the new BuddyPress api, but didn’t had time. The process of doing the new version will start next month and will have a release for WP 4.x / BP 2.x in a couple of months.