<?php $imagick = new Imagick(); $imagick->setResolution(150, 150); $imagick->readImage('beispiel.pdf'); $imagick->writeImages('converted.jpg', false); ?>
php
Damit Empfänger Umlaute vernünftig lesen kann, muss man E-Mail mit Headers (MIME, Content-type, charset) schicken.
<?php
Hier sind mehrere Beispiele, wie die Zeichenumwandlung funktioniert.
<?php
$myarray = [ "aa", "bbb", "c", "dddddd", "eeee"];
usort($myarray, 'sortbylength' );
function sortbylength($a,$b){
return strlen($b)-strlen($a);
}
echo "<pre>";
print_r( $myarray );
?>
Output:
Array (
[0] => dddddd
[1] => eeee
[2] => bbb
[3] => aa
[4] => c
)
$link = "http://www.itlantik.de/node/add/article?uuid=02516";
if( function_exists('geoip_country_code_by_name') ) {
$geoip_host = geoip_country_code_by_name( parse_url($link, PHP_URL_HOST) );
echo $geoip_host; # DE
}
- echo parse_url("//itlantik.de/dir1/file.ext?param1=val1", PHP_URL_HOST); # itlantik.de
- echo parse_url("http://itlantik.de/dir1/file.ext?param1=val1", PHP_URL_HOST); # itlantik.de
- echo parse_url("https://itlantik.de/dir1/file.ext?param1=val1", PHP_URL_HOST); # itlantik.de
Shell/Cronjob:
/usr/bin/php /home/meineseite/test.php --repeat='123'
<?php
$shellArgs = getopt('', ["repeat:", "optional2::"] );
$repeat = $shellArgs['repeat'];for( $i=0; $i<$repeat; $i++){
if( $i > 5) break; # Endlos-Schleife verhindern
shell_exec("/usr/bin/php " . __FILE__ );
}# weitere PHP-Code für üblichen Ablauf
class a {
var $str = 0;
function b(){
echo $this->str++ . ' ';
return $this;
}
}
$a = new a();
$a->b()->b()->b()->b()->b()->b()->b()->b()->b()->b()->b()->b()->b();
echo $a->str;
Wichtig ist, dass die Rückgabewert selber eine Klasse ist.
<?php
rename_function('strlen', 'new_strlen');
override_function('strlen', '$string', 'return override_strlen($string);');
function override_strlen($string){
Seitennummerierung
- Vorherige Seite
- Seite 3
- Nächste Seite
Neueste Kommentare
Same with Drush 13 + PHP 8.3 and my Solution
Same with Drush 13 + PHP 8.3
Error : Failed to install the required package 'RPM' by using AP
Initializing...
Error : Failed to install the required package 'RPM' by using APT. Please install it manually.
Exit
Solution:
Installieren & Aktivieren
So habe es installiert und dann mit Hilfe von Key/Code (über Website von Acronis Cyber Protect) aktiviert:
I have a view with a path…
I have a view with a path like
/my-content-export
to export entivies as JSON or CSV.admin_toolbar 3.5.2 is the…
admin_toolbar 3.5.2 is the reason. Patch coming ...
Tools & Settings >> Security…
Tools & Settings >> Security Policy :
Allow only secure FTPS connections
List config vaiables
/usr/sbin/mariadbd --help --verbose | grep "query.*size"
Restart MariaDB / MySQL
Commandline:
MariaDB Restart (after changes in /etc/mysql/db-performance.cnf)
After my changes in /etc/mysql/db-performance.cnf
Error: configure: error: no acceptable C compiler found in $PATH
Error: