Greeting guys i have to develop a learning site, pure php or what frameworks you suggest?

|
MrNefelim 2019-02-01 10:40:25
Короче, не нужно мешать бек и фронт)))
xalexvp 2019-02-01 10:43:27
*Исключение – фронт без JS, но ведь полно толковых лаконичных шаблонизаторов
2019-02-01 10:50:57
Aen Elle 2019-02-01 10:39:31
кароче есть такая тема, что шорт тэги у некоторых могут не работать

в основном не работают когда невалидный код, типа xml вставок в html и тд

Aen Elle 2019-02-01 10:52:19
aa
VikingBO 2019-02-01 10:52:41
Aen Elle 2019-02-01 10:39:31
кароче есть такая тема, что шорт тэги у некоторых могут не работать

Они могут не работать у тех некоторых которые понятия не имеют как настраивается сервер и в частности php, у которого есть спешл директива которая включает или отключает шорткод

2019-02-01 10:53:13
бывает такое, что и влезть туда не дают 🙁
VikingBO 2019-02-01 10:54:21
xml тут вообще не причем, если грамотно вставлять php то вопросов с ним не возникнет, с ним вопросы только в строгом синтаксисе, где любое отхождение от правил типа не писать обратный слэш для тегов br, приводит тут же к краху всей системы
VikingBO 2019-02-01 10:54:32
если не дают пиши через htaccess
VikingBO 2019-02-01 10:55:05
а если сервер вообще на nginx тогда пиши на человекопонятных системах 🙂 и выкатывай ценник соответствующий
2019-02-01 10:55:10
но вроде как <?= не регулируется директивой short_open_tag, он по дефолту же
VikingBO 2019-02-01 10:55:29
вроде да, не помню что бы с ним вооще возникали проблемы
2019-02-01 10:55:36
тоже
VikingBO 2019-02-01 10:56:05
хотя я и так то редко пользую подобное, в основном только если близкие знакомые
VikingBO 2019-02-01 10:56:23
понапишут всякой фигни на вордпрессах, копайся потом 🙂
VikingBO 2019-02-01 10:56:32
за печеньки 🙂
MrNefelim 2019-02-01 10:57:01
VikingBO 2019-02-01 10:56:23
понапишут всякой фигни на вордпрессах, копайся потом 🙂

Жумла! Написанная индусом выше

VikingBO 2019-02-01 10:57:22
MrNefelim 2019-02-01 10:57:01
Жумла! Написанная индусом выше

о, это писал сам владыка нижних миров

VikingBO 2019-02-01 10:57:34
ненавижу люто всей душой с самой первой встречи
2019-02-01 10:58:05
ну там не все так плохо, на самом деле, как могло быть
MrNefelim 2019-02-01 10:59:02
2019-02-01 10:58:05
ну там не все так плохо, на самом деле, как могло быть

Все плохо, как:
<ТелоСтраницы>Текст</ТелоСтраницы>

pratikbutani 2019-02-02 13:09:28
#PHP #Developer can help.
#GDLib #GujaratiText #Help

https://stackoverflow.com/q/54385917/1318946

GD Library imagettftext getting problem in Gujarati Language TextStack Overflow
I have used GD Library to create “Text on Image”. I am facing one issue that passing some Gujarati text but getting wrong output as below:

I want like this
and getting:
My code is:

$t…

MarvinHeemeyer 2019-02-02 14:47:51
pratikbutani 2019-02-02 13:09:28
#PHP #Developer can help.
#GDLib #GujaratiText #Help

https://stackoverflow.com/q/54385917/1318946

Try this one
$textBox = imagettfbbox($fontSize, $angle, $font, $txt);

$textBoxX = [$textBox[0], $textBox[2], $textBox[4], $textBox[6]];
$textBoxY = [$textBox[1], $textBox[3], $textBox[5], $textBox[7]];

$textWidth = max($textBoxX) – min($textBoxX);
$textHeight = max($textBoxY) – min($textBoxY);

$x = ((imagesx($img) – $textWidth) / 2) – min($textBoxX);
$y = ((imagesy($img) + $textHeight) / 2) – max($textBoxY);

// Added this line from SO answer.
$txt = mb_convert_encoding($txt, “HTML-ENTITIES”, “UTF-8”);
$txt = preg_replace(‘~^(&([a-zA-Z0-9]);)~’, htmlentities(‘${1}’), $txt);

// Outline
for($outlineY = $y – $outlineSize; $outlineY <= $y + $outlineSize; $outlineY++) {
for($outlineX = $x – $outlineSize; $outlineX <= $x + $outlineSize; $outlineX++) {
imagettftext($img, $fontSize, $angle, $outlineX, $outlineY, $white, $font, $txt);
}
}

//add the text
imagettftext($img, $fontSize, $angle, $x, $y, $maroon, $font, $txt);

pratikbutani 2019-02-02 14:50:14
MarvinHeemeyer 2019-02-02 14:47:51
Try this one
$textBox = imagettfbbox($fontSize, $angle, $font, $txt);

$textBoxX = [$textBox[0], $textBox[2], $textBox[4], $textBox[6]];
$textBoxY = [$textBox[1], $textBox[3], $textBox[5], $textBox[7]];

$textWidth = max($textBoxX) – min($textBoxX);
$textHeight = max($textBoxY) – min($textBoxY);

$x = ((imagesx($img) – $textWidth) / 2) – min($textBoxX);
$y = ((imagesy($img) + $textHeight) / 2) – max($textBoxY);

// Added this line from SO answer.
$txt = mb_convert_encoding($txt, “HTML-ENTITIES”, “UTF-8”);
$txt = preg_replace(‘~^(&([a-zA-Z0-9]);)~’, htmlentities(‘${1}’), $txt);

// Outline
for($outlineY = $y – $outlineSize; $outlineY <= $y + $outlineSize; $outlineY++) {
for($outlineX = $x – $outlineSize; $outlineX <= $x + $outlineSize; $outlineX++) {
imagettftext($img, $fontSize, $angle, $outlineX, $outlineY, $white, $font, $txt);
}
}

//add the text
imagettftext($img, $fontSize, $angle, $x, $y, $maroon, $font, $txt);

I have tried this but didn’t worked for me

MarvinHeemeyer 2019-02-02 14:50:51
prepend my code by $outlineSize = 3;
MarvinHeemeyer 2019-02-02 14:54:29
Oh, and replace $img with $this->img
appinv 2019-02-02 14:57:51
greeting guys i have to develop a learning site, pure php or what frameworks you suggest?
MarvinHeemeyer 2019-02-02 14:58:11
laravel
arturpanteleev 2019-02-02 14:59:04
appinv 2019-02-02 14:57:51
greeting guys i have to develop a learning site, pure php or what frameworks you suggest?

If it will your first expirience – use pure php

appinv 2019-02-02 14:59:19
in shared hosting do you need additional stuffs for deployment (laravel)?
appinv 2019-02-02 15:00:07
arturpanteleev 2019-02-02 14:59:04
If it will your first expirience – use pure php

i developed in php in the past but did not use security good practices etc

i am a py coder backend with flask

MarvinHeemeyer 2019-02-02 15:00:28
Any DB, if u planing store data on server side )
MrNefelim 2019-02-02 15:00:32
appinv 2019-02-02 15:00:07
i developed in php in the past but did not use security good practices etc

i am a py coder backend with flask

Why not Django?

appinv 2019-02-02 15:00:34
mySQL
appinv 2019-02-02 15:00:58
MrNefelim 2019-02-02 15:00:32
Why not Django?

easy routing and running

arturpanteleev 2019-02-02 15:02:12
appinv 2019-02-02 15:00:07
i developed in php in the past but did not use security good practices etc

i am a py coder backend with flask

Do you have some trouble with information security?

MrNefelim 2019-02-02 15:02:16
appinv 2019-02-02 15:00:58
easy routing and running

Is the flask still supported?

arturpanteleev 2019-02-02 15:02:18
This site can help you
arturpanteleev 2019-02-02 15:02:28
https://www.hacksplaining.com/

Hacksplaining: Security Training for DevelopersHacksplaining
The best protection against being hacked is well-informed developers. Make your development team into security experts today. %>
appinv 2019-02-02 15:04:36
MrNefelim 2019-02-02 15:02:16
Is the flask still supported?

django best as all features in it. orm, admin panel etc etc etc etc

flask more modular but saves me on using regex for routes. classifying routes can be done via blueprints

appinv 2019-02-02 15:05:39
arturpanteleev 2019-02-02 15:02:28
https://www.hacksplaining.com/

thanks.

ok guys i plan to use pure php as i am not an expert in php

planning to learn laravel soon. any good tuto?

MarvinHeemeyer 2019-02-02 15:06:52
https://laravel.com/docs/

Laravel – The PHP Framework For Web ArtisansLaravel
Laravel is a PHP web application framework with expressive, elegant syntax. We’ve already laid the foundation — freeing you to create without sweating the small things.
appinv 2019-02-02 15:12:35
arturpanteleev 2019-02-02 15:02:28
https://www.hacksplaining.com/

gooood has both py and php code samples

appinv 2019-02-02 15:12:41
MarvinHeemeyer 2019-02-02 15:06:52
https://laravel.com/docs/

👍❤️

appinv 2019-02-03 20:14:02
greetings, best php orm?
MrNefelim 2019-02-03 20:14:39
appinv 2019-02-03 20:14:02
greetings, best php orm?

Doctrine

appinv 2019-02-03 20:16:38
tell me they all require composer, that’s a pain for someone knowing only core php
appinv 2019-02-03 20:17:09
guess must get used to it
MrNefelim 2019-02-03 20:19:38
Learn composer
appinv 2019-02-03 21:09:56
i guess i’ll do that next. by tomorrow
MrNefelim 2019-02-03 21:11:00
appinv 2019-02-03 21:09:56
i guess i’ll do that next. by tomorrow

You can use composer to include the files manually. However, I advise you to study the autoloader function.

|