צפייה באתר תחת SSL – להכריח את המשתמש – Apache Mod Rewrite

ספט' 24

לפעמים אתה צריך לוודא שהמשתמש צופה באתר תחת SSL ישנה דרך פשוטה לבצע פעולה זו על ידי הכרחת המשתמש לצפות באתר תחת הקידומת HTTPS ולא HTTP בכדי לבצע זאת כל מה שליכם לעשות הוא להוסיף את השורות הבאות לקובץ ה .htaccess...

Read More

Apache rewrite rules – Http to Https – Force SSL

ספט' 24

Sometimes you may need to make sure that the user is browsing your site over securte connection. An easy to way to always redirect the user to secure connection (https://) can be accomplished with a .htaccess file containing the following lines: RewriteEngine On RewriteCond %{SERVER_PORT} 80 RewriteRule ^(.*)$ https://www.example.com/$1 [R,L] Please, note that...

Read More

קבלת עומס השרת כרגע – SERVER LOAD

ספט' 24

פונקציה אשר מחזירה את זמן טעינת השרת SERVER LOAD תומכת ברוב מערכות ההפעלה כיום. <?php /** * Retrieve server load * * NOTE: You should cache the value returned to perform the check every X sec/min * To reduce the page load time. * * @return string Server load */ function...

Read More

Get server load time

ספט' 24

This is a simple script that will display the server load time works on most OS <?php /** * Retrieve server load * * NOTE: You should cache the value returned to perform the check every X sec/min * To reduce the page load time. * * @return string Server load */ function getServerLoad() { $load_limit = ""; // Get the server load if loadavg...

Read More