Home » Archive for January 2023
Resolve adding the following code to the WordPress theme function.php file. HIGHLY recommend creating a child theme and using functions.php from that theme. add_filter('widget_text','execute_php',100);
function execute_php($html){ if(strpos($html,"<"."?php")!==false){ ob_start(); eval("?".">".$html); $html=ob_get_contents(); ob_end_clean(); } return $html;
} To enable shortcodes in the Text
Navigate to your httpd.conf file (xamppapacheconf) and open it using your favourite text editor. If you do not have access to this folder/file, open your .htaccess file instead. Underneath the "#LoadModule" lines, add the following: # Instruct the browser to always check for the latest version of your files using Apache directives
<IfModule mod_headers.c> <FilesMatch
Since the release of PDF.js 2.0.943 you can force URL to open in a new tab: <script> function applyConfig() { PDFViewerApplication.preferences.set('externalLinkTarget', 2); } document.addEventListener('DOMContentLoaded', applyConfig, true);
</script> Older versions we used: PDFJS.externalLinkTarget = PDFJS.LinkTarget.BLANK; This is also a hack that might work on newer versions but
This code shows using a database but can easily be adopted for direct use. // Database Connection $conn = new mysqli('hostname', 'username', 'password', 'database');
//Check for connection error
$select = "SELECT * FROM `infopdf`";
$result = $conn->query($select);
while($row = $result->fetch_object()){ $pdf = $row->filename; $path = $row->directory; $date = $row->created_date;
cache.php content: class CachingClass
{ var $cache_time = null; var $file_name = null; function __construct( $file_name, $cache_time = 0 ) { $this->cache_time = ( $cache_time > 0 ) ? $cache_time : (300 * 60); $this->file_name = $file_name; } function startBuffering( ) { ob_start(); } function stopBuffering( ) { $fp = fopen($this->file_name, 'w'); fwrite($fp, ob_get_contents());
So you forgot your WordPress password... Login to hosting control panel
Go to PhpMyAdmin
Click on your WordPress database and view list of tables in the database.
Locate the 'wp_users' table. If you have changed the table prefix during the WordPress installation, then look for 'prefix_wp_users' table. Click on the browse link next to it.
You should now see entries in your WordPress users table.
Designed for web browsers based on the WebKit code library, such as Google Chrome. This code makes use of the WebKit-specific “webkitGetUserMedia” function, as a generic implementation of “getUserMedia” that works in the same way in all browsers has not yet been decided on. It should also be noted that it might be a fairly trivial task to modify the code to work in other browsers.
Disable system-wide lid actions by editing /etc/systemd/logind.conf and see if it works (you can also use lock instead of ignore): HandleLidSwitch=ignore
HandleLidSwitchExternalPower=ignore
HandleLidSwitchDocked=ignore Apply changes: sudo systemctl kill -s HUP systemd-logind