Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  nodelist  faq  

What we see depends on mainly what we look for. -- John Lubbock


rocksolid / Helpdesk / Re: Could Not Open Font

SubjectAuthor
* Could Not Open FontAnonymous
+* Re: Could Not Open FontAnonymous
|+- Re: Could Not Open FontAnonymous
|`- Re: Could Not Open FontAnonymous
+- Re: Could Not Open FontAnonymous
+- Font pathAnonymous
`* Re: Could Not Open FontAnonymous
 `* Re: Could Not Open Fonttrw
  `- Re: Could Not Open Fonttrw

1
Subject: Could Not Open Font
From: Anonymous
Newsgroups: rocksolid.shared.helpdesk
Organization: novaBBS
Date: Sat, 19 Dec 2020 03:07 UTC
Path: i2pn2.org!.POSTED!not-for-mail
From: Anonym...@novabbs.i2p (Anonymous)
Newsgroups: rocksolid.shared.helpdesk
Subject: Could Not Open Font
Date: Sat, 19 Dec 2020 03:07:18 +0000
Organization: novaBBS
Message-ID: <9dc25e2233c8ae27a8266fe0f8e4b9a8$1@news.novabbs.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Info: i2pn2.org; posting-account="retrobbs1";
logging-data="21707"; mail-complaints-to="usenet@i2pn2.org"
User-Agent: Rocksolid Light (news.novabbs.com/getrslight)
X-Rslight-Site: $2y$10$nt8Jal/lHPezTfnsmlHWQO6l0qoFROJiKRqQYtob2122LpY6L/0/G
View all headers
Hello. I’m in a bit of a pickle right now. I’m currently using an Ubuntu Linux distribution. I’m trying to make a captcha system, but the image keeps on returning blank. I looked into the error logs of my web server, and the error logs say, “PHP message: PHP warning: imagettftext( ): Could not find/open don’t in (not comfortable sharing directory) on line 23”. Here is part of my code:

$dir = ‘Computer/usr/share/fonts/truetype/28DaysLater.ttf’ ;
imagettftext($image, {number}, {number}, {number}, {number}, $color, $dir, $_SESSION[‘captcha_code’]) ;

By the way, the {number} parts are parts that I feel somewhat insecure sharing and are also parts that I think are unimportant. I don’t think that there are any other bits of my code that are important to know, although please let me know if there’s any specific information or code that I can provide you. Anyway, I don’t know why I keep on getting this error and an empty captcha. Can somebody please give me some advice on how to solve this problem, like any downloads to make or any typing mistakes I may have made?
--
Posted on novaBBS
news.novabbs.com


Subject: Re: Could Not Open Font
From: Anonymous
Newsgroups: rocksolid.shared.helpdesk
Organization: Rocksolid Light
Date: Sat, 19 Dec 2020 03:18 UTC
Path: i2pn2.org!rocksolid2!.POSTED.localhost!not-for-mail
From: Anonym...@rslight.i2p (Anonymous)
Newsgroups: rocksolid.shared.helpdesk
Subject: Re: Could Not Open Font
Date: Sat, 19 Dec 2020 03:18:45 +0000
Organization: Rocksolid Light
Message-ID: <2257307b0a1ebf048a8f52c9225ab093$1@rslight.i2p>
References: <9dc25e2233c8ae27a8266fe0f8e4b9a8$1@news.novabbs.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Info: novabbs.org; posting-account="retrobbs1"; posting-host="localhost:127.0.0.1";
logging-data="31910"; mail-complaints-to="usenet@novabbs.org"
User-Agent: Rocksolid Light (news.novabbs.com/getrslight)
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on novabbs.org
X-Rslight-Site: $2y$10$aq2hac8ESBTTkM0K7bMVBuw3czkOilDYJvATpSU7HrH6H9.YsFm4K
View all headers
Anonymous wrote:

Hello. I’m in a bit of a pickle right now. I’m currently using an Ubuntu Linux distribution. I’m trying to make a captcha system, but the image keeps on returning blank. I looked into the error logs of my web server, and the error logs say, “PHP message: PHP warning: imagettftext( ): Could not find/open don’t in (not comfortable sharing directory) on line 23”. Here is part of my code:

Simple question in case you may be overlooking something obvious. The error says can't find "don't" in a particular directory. Is "don't" really a file name you want? Is the directory it's looking in correct? Does what you want it to find exist in that directory? Does you web server 'user' have read access to that directory?

$dir = ‘Computer/usr/share/fonts/truetype/28DaysLater.ttf’ ;
imagettftext($image, {number}, {number}, {number}, {number}, $color, $dir, $_SESSION[‘captcha_code’]) ;

Does $dir need a leading slash '/'?

--
Posted on Rocksolid Light
rslight.i2p


Subject: Re: Could Not Open Font
From: Anonymous
Newsgroups: rocksolid.shared.helpdesk
Organization: Rocksolid Light
Date: Sat, 19 Dec 2020 03:20 UTC
Path: i2pn2.org!rocksolid2!.POSTED.localhost!not-for-mail
From: Anonym...@rslight.i2p (Anonymous)
Newsgroups: rocksolid.shared.helpdesk
Subject: Re: Could Not Open Font
Date: Sat, 19 Dec 2020 03:20:48 +0000
Organization: Rocksolid Light
Message-ID: <46349c2498b402b6022f167dc1fa6587$1@rslight.i2p>
References: <9dc25e2233c8ae27a8266fe0f8e4b9a8$1@news.novabbs.com> <2257307b0a1ebf048a8f52c9225ab093$1@rslight.i2p>
Mime-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Info: novabbs.org; posting-account="retrobbs1"; posting-host="localhost:127.0.0.1";
logging-data="366"; mail-complaints-to="usenet@novabbs.org"
User-Agent: Rocksolid Light (news.novabbs.com/getrslight)
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on novabbs.org
X-Rslight-Site: $2y$10$ERe8H8BFNuPCE/TTj3t/Iejks6oIYJ91xCM/17dmcWBejwQsfLMIW
View all headers
Anonymous wrote:

Anonymous wrote:

Hello. I’m in a bit of a pickle right now. I’m currently using an Ubuntu Linux distribution. I’m trying to make a captcha system, but the image keeps on returning blank. I looked into the error logs of my web server, and the error logs say, “PHP message: PHP warning: imagettftext( ): Could not find/open don’t in (not comfortable sharing directory) on line 23”. Here is part of my code:

Simple question in case you may be overlooking something obvious. The error says can't find "don't" in a particular directory. Is "don't" really a file name you want? Is the directory it's looking in correct? Does what you want it to find exist in that directory? Does you web server 'user' have read access to that directory?

$dir = ‘Computer/usr/share/fonts/truetype/28DaysLater.ttf’ ;
imagettftext($image, {number}, {number}, {number}, {number}, $color, $dir, $_SESSION[‘captcha_code’]) ;

Does $dir need a leading slash '/'?

Also, $dir is not a dir, it's a file (28DaysLater.ttf). Is that meant to be the full filename with path, or really a dir?



--
Posted on Rocksolid Light
rslight.i2p


Subject: Re: Could Not Open Font
From: Anonymous
Newsgroups: rocksolid.shared.helpdesk
Organization: novaBBS
Date: Sat, 19 Dec 2020 04:52 UTC
Path: i2pn2.org!.POSTED!not-for-mail
From: Anonym...@novabbs.i2p (Anonymous)
Newsgroups: rocksolid.shared.helpdesk
Subject: Re: Could Not Open Font
Date: Sat, 19 Dec 2020 04:52:07 +0000
Organization: novaBBS
Message-ID: <efca9aca1e07f1d4c20aacc89ee2687f$1@www.novabbs.com>
References: <9dc25e2233c8ae27a8266fe0f8e4b9a8$1@news.novabbs.com> <2257307b0a1ebf048a8f52c9225ab093$1@rslight.i2p>
Mime-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Info: i2pn2.org; posting-account="retrobbs1";
logging-data="4329"; mail-complaints-to="usenet@i2pn2.org"
User-Agent: Rocksolid Light (news.novabbs.com/getrslight)
X-Rslight-Site: $2y$10$7DgV81aK2wrhVPC.L0Kre.KK8o9Fl.7uOuVIxK.Arw41KNa.3UJke
View all headers
AH! Sorry. I didn’t actually mean to write “don’t”, but really “font”. Please ignore that clumsy mistake.
--
Posted on novaBBS
www.novabbs.com


Subject: Re: Could Not Open Font
From: Anonymous
Newsgroups: rocksolid.shared.helpdesk
Organization: Rocksolid Light
Date: Sat, 19 Dec 2020 05:25 UTC
Path: i2pn2.org!rocksolid2!.POSTED.localhost!not-for-mail
From: Anonym...@rslight.i2p (Anonymous)
Newsgroups: rocksolid.shared.helpdesk
Subject: Re: Could Not Open Font
Date: Sat, 19 Dec 2020 05:25:39 +0000
Organization: Rocksolid Light
Message-ID: <cbd64428bdd051fb392f528f8847f0f2$1@rslight.i2p>
References: <9dc25e2233c8ae27a8266fe0f8e4b9a8$1@news.novabbs.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Info: novabbs.org; posting-account="retrobbs1"; posting-host="localhost:127.0.0.1";
logging-data="30326"; mail-complaints-to="usenet@novabbs.org"
User-Agent: Rocksolid Light (news.novabbs.com/getrslight)
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on novabbs.org
X-Rslight-Site: $2y$10$iWFYm4/Dx2OB8Qum61KW7.nqkt8re/ZBRs8o6R50iQR.bLUj4IRhO
View all headers
Anonymous wrote:

Hello. I’m in a bit of a pickle right now. I’m currently using an Ubuntu Linux distribution. I’m trying to make a captcha system, but the image keeps on returning blank. I looked into the error logs of my web server, and the error logs say, “PHP message: PHP warning: imagettftext( ): Could not find/open don’t in (not comfortable sharing directory) on line 23”. Here is part of my code:

$dir = ‘Computer/usr/share/fonts/truetype/28DaysLater.ttf’ ;
imagettftext($image, {number}, {number}, {number}, {number}, $color, $dir, $_SESSION[‘captcha_code’]) ;

Is $dir relative to where you are running the script? Are you sure 28DaysLater.ttf is accessible using the exact path you're passing to $dir?

--
Posted on Rocksolid Light
rslight.i2p


Subject: Font path
From: Anonymous
Newsgroups: rocksolid.shared.helpdesk
Organization: rocksolid2 (novabbs.org)
Date: Sat, 19 Dec 2020 10:12 UTC
Path: i2pn2.org!rocksolid2!.POSTED.127.117.190.215!not-for-mail
From: pos...@anon.com (Anonymous)
Newsgroups: rocksolid.shared.helpdesk
Subject: Font path
Date: Sat, 19 Dec 2020 02:12:37 -0800
Organization: rocksolid2 (novabbs.org)
Message-ID: <he.652.btp54@anon.com>
References: <9dc25e2233c8ae27a8266fe0f8e4b9a8$1@news.novabbs.com>
Content-Type: text/plain; charset=UTF-8
Injection-Info: novabbs.org; posting-account="def.i2p"; posting-host="127.117.190.215";
logging-data="18840"; mail-complaints-to="usenet@novabbs.org"
View all headers
Seems like you need to give the path of the font a leading /, like this:
$dir = ‘/Computer/usr/share/fonts/truetype/28DaysLater.ttf’ ;

Look here:
https://stackoverflow.com/questions/10366679/warning-imagettftext-function-imagettftext-could-not-find-open-font-in-ho#10366726
and here:
https://www.php.net/manual/en/function.imagettftext.php

--
Posted on def2


Subject: Re: Could Not Open Font
From: Anonymous
Newsgroups: rocksolid.shared.helpdesk
Organization: novaBBS
Date: Sun, 20 Dec 2020 00:47 UTC
Path: i2pn2.org!.POSTED!not-for-mail
From: Anonym...@novabbs.i2p (Anonymous)
Newsgroups: rocksolid.shared.helpdesk
Subject: Re: Could Not Open Font
Date: Sun, 20 Dec 2020 00:47:00 +0000
Organization: novaBBS
Message-ID: <02b50a3881ede4ef7eededd8bad8ae3e$1@news.novabbs.com>
References: <9dc25e2233c8ae27a8266fe0f8e4b9a8$1@news.novabbs.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Info: i2pn2.org; posting-account="retrobbs1";
logging-data="18732"; mail-complaints-to="usenet@i2pn2.org"
User-Agent: Rocksolid Light (news.novabbs.com/getrslight)
X-Rslight-Site: $2y$10$Z8XDsI1sTYFSo6C.YoEIIeejoTlizzyMpWRsyQ1dCULt0RNADh2ju
View all headers
Solved! Apparently, I was using the wrong path the entire time...
Thank you for trying to help me with the problem, as I got the answer from a post here.
--
Posted on novaBBS
news.novabbs.com


Subject: Re: Could Not Open Font
From: trw
Newsgroups: rocksolid.shared.helpdesk
Organization: def5
Date: Sun, 20 Dec 2020 01:23 UTC
Path: i2pn2.org!rocksolid2!def5!POSTED.localhost!not-for-mail
From: trw...@anon.com (trw)
Newsgroups: rocksolid.shared.helpdesk
Message-ID: <6f8613c44438fcc5616deaa71a2ec7d1@def4>
Subject: Re: Could Not Open Font
Date: Sun, 20 Dec 2020 01:23:26+0000
Organization: def5
In-Reply-To: <02b50a3881ede4ef7eededd8bad8ae3e$1@news.novabbs.com>
References: <02b50a3881ede4ef7eededd8bad8ae3e$1@news.novabbs.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
View all headers

Good you could get it solved, and thanks for updating on the final solution.

cheers

trw

--
Posted on def4


Subject: Re: Could Not Open Font
From: trw
Newsgroups: rocksolid.shared.helpdesk
Organization: def5
Date: Sun, 20 Dec 2020 02:15 UTC
Path: i2pn2.org!rocksolid2!def5!POSTED.localhost!not-for-mail
From: trw...@anon.com (trw)
Newsgroups: rocksolid.shared.helpdesk
Message-ID: <04cd9445ca3b8cb3cb71f288578a2781@def4>
Subject: Re: Could Not Open Font
Date: Sun, 20 Dec 2020 02:15:42+0000
Organization: def5
In-Reply-To: <6f8613c44438fcc5616deaa71a2ec7d1@def4>
References: <6f8613c44438fcc5616deaa71a2ec7d1@def4>
Mime-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 8bit
View all headers

and don't forget to advertise your sites address here, once you have it done :-)


--
Posted on def4


1
rocksolid light 0.6.9
clearneti2ptor