How to quote?
PHP web-programming
Hello Guest
  
  • Login
• Register…
• Start blog
  • Who, Where, When
• What is interesting here?
• Duels
  • Polls
• Avatars
• Interests
  • Cities and Countries
• Random blog
• Users search
  • Search
• Games
• Tests
• QAIX
  • Сообщества
• Talxy Chat
• Horoscope
• Online
 
Register!

QAIX > PHP web-programmingGo to page: 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | next »

  Top users: 
  Recent blog posts: 
  They have birthday today: 
  Forums:   
  Discuss: 
  Recent forum topics: 
  Recent forum comments:
  Модератор:
Monday, 15 February 2010
How to find <img> tag and get src of image Pham Huu Le Quoc Phuc 21:05:04
 Hi everybody!
I want to get src of image form a $text, I have a below text

$Text = <table border="1" cellpadding="3%" cellspacing="3%" width="100%">
<tr> <td width="20%">
<img align="middle" border="0" id=userupload/78/Au­tumn.jpg
src=userupload/78/A­utumn.jpg onClick="javascript­:ViewImage(this.id);­"
width="100" height="100" >
</td>
<td></td></tr> </table>
</td>
<td class="frame2_middl­e_right"></td>
</tr>
<tr>
<td class="frame2_botto­m_left"></td>
<td class="frame2_botto­m_center">
</td>

--
PHP General Mailing List (http://www.php.net­/)
To unsubscribe, visit: http://www.php.net/­unsub.php


comment 6 answers | Add comment
Tuesday, 9 February 2010
Call to undefined function printer_open() saritha 10:07:23
 hie,i am attempting to use printer_open() but i am receiving the following error when i test through dl()

dl() [function.dl]: Not supported in multithreaded Web servers - use extension=printer in your php.ini in C:\AppServ\www\fyp\­ext_load.php on line 3

This is my code:
<?php
// Example loading an extension based on OS
if (!extension_loaded(­'printer'))
{
if (strtoupper(substr(­PHP_OS, 0, 3) == 'WIN'))
{
dl('printer');
}
else {
dl('printer.so');
}
}
// Or, the PHP_SHLIB_SUFFIX constant is available as of PHP 4.3.0
if (!extension_loaded(­'printer'))
{
$prefix = (PHP_SHLIB_SUFFIX == 'dll') ? 'php_' : '';
dl($prefix . 'printer.' . PHP_SHLIB_SUFFIX);
}
?>

why i cant load it? i am using AppServ 2.5.9.
i did the following configuration.
extension_dir = "C:\AppServ\php5\ex­t"

//uncommenting the wants one
;extension=php_mssq­l.dll
extension=php_mysql­.dll
;extension=php_mysq­li.dll
extension=php_print­er.dll

i have copied php_printer.dll into ext directory and libmysql.dll in c:/windows/system32­
comment 1 answer | Add comment
Tuesday, 26 January 2010
MinDmix.ru Ltalk.ru BeOn.ru Carguru... Ren 12:38:41
 MinDmix.ru Ltalk.ru BeOn.ru Carguru.ru
Gyxe.com Qaix.com Xywe.com
comment 7 answers | Add comment
Thursday, 21 January 2010
query strings(still broken) Sunfire 02:41:19
 tried everything except session vars and the query string is still broken...
no matter what i do for some reason the browser wants to always put %20 in
the middle of my words (i.e. hello world as one var will come out as
hello%20world)

any other ideas




---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft­.com).
Version: 6.0.458 / Virus Database: 257 - Release Date: 2/24/2003


--
PHP General Mailing List (http://www.php.net­/)
To unsubscribe, visit: http://www.php.net/­unsub.php


comment 5 answers | Add comment
file uploads Joseph Bannon 02:41:15
 Regarding file uploads...

1) Do the temp files automatically delete, or do I
need to put something in the code to delete them?

2) If automatically, how long? Where can I set the
length of time until they are deleted?

3) If not, is there a place I can make it be
automatic?


Thanks
Joseph

___________________­____________________­___________
Do you Yahoo!?
Yahoo! Tax Center - forms, calculators, tips, more
http://taxes.yahoo.­com/

--
PHP General Mailing List (http://www.php.net­/)
To unsubscribe, visit: http://www.php.net/­unsub.php


comment 33 answer | Add comment
[mysql]help with displaying table {off subject}#2 Karl James 02:41:10
 
comment 1 answer | Add comment
Tuesday, 12 January 2010
Topic awaiting moderation clothing 11:53:34
Friday, 8 January 2010
Topic awaiting moderation 351166 08:59:04
Topic awaiting moderation 351100 08:58:38
Sunday, 13 December 2009
S11213G2 If you still want to buy a... Guest 03:14:21
 S11213G2 If you still want to buy a beautiful shape for the shape of a pair of cheap ugg boots,heels and soles of ugg boots sale may wish to choose a high degree of moderate, upper lower than the ankle, to the greatest degree of pull-legs type of style.Shorter upper of ugg women boots means that it can be with any style of skirts and pants to do with.Such comfortable ugg nightfall boots are particularly suitable for light legs wearing uggs boots,even if your legs need not care about skin color pale.Of course, if you are worried about the cold feet,or discount ugg boots grinding foot and ankle can also add a pair of socks----I can guarantee that they are certainly not a bad look. http://www.topuggsa­le.com/specials.html­
Add comment
Monday, 23 November 2009
PDFLIB error 2516 Jack van Zanen 17:12:39
 Hi All,
I upgraded my test system to 4.3.9 (from 4.3.4) and now run into problems
with pdf creation. Scripts that ran fine before now return the following
error:

Fatal error: PDFlib error: [2516] PDF_findfont: Metrics data for font
'Arial' not found in d:\website\pdf_grap­h.php on line 50


Has anybody seen this before and knows of the solution? Google returned no
hits that solved the problem.

<snip>

pdf_open_file($pdf,­ "d:\\website\\graph­s.pdf");

pdf_set_info($pdf, "Author", "Automatically Generated");
pdf_set_info($pdf, "Title", "Management graphs");
pdf_set_info($pdf, "Creator", "Jacob A. van Zanen");
pdf_set_info($pdf, "Subject", "Management Graphs");



pdf_begin_page($pdf­, 700, 600);
$bookmark1 = pdf_add_bookmark($p­df, "Information for machine SBPXXA1");
$arial = pdf_findfont($pdf, "Arial", "host", 1); pdf_setfont($pdf, $arial,
12); //-----this is line 50
pdf_show_xy($pdf, "1Information for machine SBPXXA1 for $_POST[day]/
$_POST[month]/$_POST[year]",50, 510);


</snip>



TiA

Jack van Zanen




comment 4 answer | Add comment
Thursday, 12 November 2009
Loading GIF images Jason Freemen 01:10:23
 Hi there can anyone point me to an example of how to load specifically GIF images and display them in a GTK window.

Thanks
comment 4 answer | Add comment
object oriented approach Szilard Novaki 01:09:57
 Hi!

I'm a newbie at php-gtk. It's very impressive, but i'd like to use it in
object oriented way.

I've read a hello-world application. It very simple, but I could not
convert it to an object oriented structure, because the event callback
(as far as I see) is a php function. Could anyone send me an object
oriented php-gtk application, where the gtk widgets are objects? A hello
world application would be just fine.

Thank you,
Szilard

--
PHP-GTK General Mailing List (http://gtk.php.net­/)
To unsubscribe, visit: http://www.php.net/­unsub.php


comment 6 answers | Add comment
Friday, 9 October 2009
PHP - grabbing a thumb from FLV's (function) Jason Paschal 10:51:08
 i wanted to get my server to grab a thumbnail (video capture) of an FLV
using PHP, and ffmpeg-php is not an option (at the moment, can't spare the
possible downtime, many money-making sites involved).

i installed ffmpeg. Fedora Core 4 users try this:

yum install ffmpeg

I went a more circuitous route and installed Subversion (SVN) (google it),
THEN installed ffmpeg using the link on their download page. (get it,
configure it, make it)

Then, like i do with imageMagick, i use a system() call to ffmpeg.

NOTE: (i had to put the full path to ffmpeg (usr/local/bin/ffmp­eg) in my
system call, this messed me up for a bit)

here's my impromptu function (have to pass the FLV file, width, height,
hour, min, sec, append (any value you want to put on the end of the
resulting jpg's filename)):

function
flvThumb($file,$wid­th=50,$height=50,$ho­ur=00,$min=00,$sec=0­1,$append) {
if ($append == "") {
$append = time();
}

if ($file == "" or !is_file($file)) {
return false;
}

$width = eregi_replace("[^0-9]",""­,$width);
$height = eregi_replace("[^0-9]",""­,$height);

if ($width == "") {
$width = 50;
}
if ($height == "") {
$height = 50;
}

$hour = eregi_replace("[^0-9]",""­,$hour);
$min = eregi_replace("[^0-9]",""­,$min);
$sec = eregi_replace("[^0-9]",""­,$sec);

if (strlen($hour) == 1) {
$hour = "0" . $hour;
}
if (strlen($min) == 1) {
$min = "0" . $min;
}
if (strlen($sec) == 1) {
$sec = "0" . $sec;
}

$try = explode(".",$file);­
$ext = array_pop($try);
$desig = implode(".",$try);
$thumbname = $desig . "_" . $append . "." . "jpg";

$varmake = @system("/usr/local­/bin/ffmpeg -i $file -vcodec png -vframes 1
-an -f rawvideo -s " . $width . "x" . $height . " -ss " . "$hour" . ":" .
"$min" . ":" . "$sec" . " -y " . "$thumbname",$retva­l);
$tmp = @stat($thumbname);
if ($tmp['size'] == 0) {
@unlink($thumbname)­;
return false;
}
if ($retval != 0) {
return false;
} else {
return $thumbname;
}

}
if it returns anything but false, you may have a problem. of course, the
problem may be with the function and application.

i know that improvements can be made, but i wish i had seen this before i
started trying to figure everything out. i like having a starting point.
(i'm sending this to my gmail for my 'reference archive')

HOPE THIS HELPS SOMEONE
(plz don't burn me)

1337 c0d1ng 2 a11, & 2 a11 @ g00d n173,
mellomutt

p.s. it only just now strikes me that many other video formats can be
thumbnailed. mpg, wmv, mov, avi, etc.... this really changes the way i'm
thinking about my sites. i was using a desktop client to make thumbnails,
and it's a good one, but to have ur server do it for you...that just makes
it that much easier to add content, and thusly, that much more likely for me
to add content because i'm a lazy wanker.
Add comment
[SMARTY] FCKeditor and Smarty Chris Hubbard 10:51:01
 A bit ago, someone asked about FCKeditor and Smarty. I spent some time
on it, and here's one implementation.

PHP file, edit.php:
<?php
require_once ("../config/config.­php");
require_once ("../libs/FCKeditor­/fckeditor.php") ;

if (array_key_exists("­FCKeditor1", $_POST))
{
// echo "<pre>";
// print_r($_POST);
// echo "</pre>";
$bytes = file_put_contents("­../templates/right_c­ol.tpl",
$_POST['FCKeditor1']);
}

$sBasePath = "../libs/FCKeditor/­";

$right_col = file_get_contents("­../templates/right_c­ol.tpl");
$oFCKeditor = new FCKeditor('FCKedito­r1') ;
$oFCKeditor->BasePa­th = $sBasePath ;
$oFCKeditor->Value = $right_col;
$oFCKeditor->Height­ = '400';

$tpl->assign("data"­, $oFCKeditor->Create­Html()) ;
$tpl->display("edit­.tpl");
?>

Comments about edit.php
1. the config.php include contains the standard code to instantiate
smarty with $tpl as the object reference
2. I put FCKeditor folder in ../libs, which isn't a web browsable
location. For this example, it doesn't really matter where it goes,
for security, it does matter.
3. Make sure you get the $sBasePath right. If you don't it won't work
at all.
4. The standard FCKeditor examples use $oFCKeditor->Create­(). But
that method echos the FCKeditor stuff. What we want it the FCKeditor
stuff returned so we can assign it to Smarty. Luckly FCKeditor has the
CreateHtml() method which is exactly what is needed.
5. This example uses the PHP5 file_get_content and file_put_content()
functions. If you're running PHP4.x either get the PHPCompat library,
or use fopen, fgets, fclose, and fopen, fputs, fclose instead.

Template file, edit.tpl:
<html xmlns="http://www.w­3.org/1999/xhtml" lang="en_US"
xml:lang="en_US">

<head>
<title> </title>

</head>

<body>
<form action="edit.php" method="post">
{$data}
<br>
<input type="submit" value="Submit">
</form>

</body>
</html>

Comments about edit.tpl
1. um... nothing very interesting here.

Note, this example illustrates how to get FCKeditor working with
Smarty. In real life you would have all kinds of security measures in
place to prevent people doing bad things.

If there's enough interest to create an actual Smarty custom function,
I will, but it's easy enough as it is.
Chris

comment 2 answer | Add comment
Saturdays and Sundays Shaun 10:50:44
 Hi,

Is it possible to get the number of saturdays and sundays for a given month
/ year?

Thanks for your help.

--
PHP General Mailing List (http://www.php.net­/)
To unsubscribe, visit: http://www.php.net/­unsub.php


comment 9 answers | Add comment
Wednesday, 9 September 2009
Topic awaiting moderation edhardyhive 04:00:04
Topic awaiting moderation edhardyhive 03:58:38
Friday, 14 August 2009
wwwwwwwwwwwwwwwwwwww­wwwwwwwwwwwwwwwwwwww­wwwwwwwwwwwwwwwwwwww­wwwwwwwwwwwwwwwwwwww­wwwwwwwwwwwwww Erik Hegreberg 19:49:01
 
Add comment
Friday, 24 July 2009
ocilogon Adam Williams 10:09:06
 Hi, what is the syntax for using ocilogon() to connect to a remote server?
The remote server's name is zed.mdah.state.ms.u­s (ip is 10.8.5.4) and the
database is zed.aleph0. Locally on zed I can do
ociogon("user","pw"­,"zed.alpeh0") and connect fine, but on a remote server
I try ociogon("user","pw"­,"zed.alpeh0@10.8.5.­4") but it errors out with an
oci_open_server error. I tried going to www.php.net/ocilogo­n but the page
doesn't exist, so does anyone know how the proper connect line to
connect to a remote server that runs oracle? Thanks!

--
PHP General Mailing List (http://www.php.net­/)
To unsubscribe, visit: http://www.php.net/­unsub.php


comment 5 answers | Add comment
Tuesday, 14 July 2009
[SMARTY] Setting session variable from template? John Wells 11:16:41
 I'm trying to find a way to set a session variable from within a
template. I've tried

{php}
$_SESSION['selected_id'] = "$selected_id";
{/php}

and

{assign var="smarty.session­.id" value="Bob"}

Neither works. Is there a way to do this?

Thanks!
John

--
Smarty General Mailing List (http://smarty.php.­net/)
To unsubscribe, visit: http://www.php.net/­unsub.php


comment 1 answer | Add comment
Wednesday, 1 July 2009
Clear POST variables on page refresh Richard Morley 08:14:21
 I'm not sure if this is specifically a PHP problem, but here we go. Is
there a way to clear the POST variables when the user refreshes a page?
Specifically, my webpage POSTs a form to update or delete a record from
the database -- it POSTs to itself, however. But if the user then clicks
the browser's refresh button, it will try to delete or modify a
non-existent record. I would like, if the users presses the refresh
button, that PHP processes the page as no POST variables are set. I have a
button on the page entitled "Reload" that executes a short Javascript:
onclick=window.loca­tion=<? echo PHP_SELF; ?> which accomplishes the
desired effect. But it tries to resend the POST information if the browser
refresh button is clicked.

I read something somewhere that seemed to imply this could be done with
PHP sessions? Is this the way to go? If so, how?

Thanks for any help.

Richard Morley

--
PHP General Mailing List (http://www.php.net­/)
To unsubscribe, visit: http://www.php.net/­unsub.php


comment 9 answers | Add comment
Wednesday, 24 June 2009
get output in .html file Martin 12:17:45
 Does somebody know how to get the output of an .php file into an .html file
(server side). This in order to cache generated pages for futur visitors.

thanks

Martin

--
PHP General Mailing List (http://www.php.net­/)
To unsubscribe, visit: http://www.php.net/­unsub.php


comment 3 answer | Add comment
Monday, 25 May 2009
[SMARTY] break out of foreach-loop Stefan Sturm 15:52:31
 Hello list,

my question:

I have a foreach-loop. How can I break this loop before it ends?

Greetings,

Stefan Sturm


--
Smarty General Mailing List (http://smarty.php.­net/)
To unsubscribe, visit: http://www.php.net/­unsub.php


comment 6 answers | Add comment

Add new topic:

How:  Register )
 
Login:   Password:   
Comments by: Premoderation:
Topic:
  
 
Пожалуйста, относитесь к собеседникам уважительно, не используйте нецензурные слова, не злоупотребляйте заглавными буквами, не публикуйте рекламу и объявления о купле/продаже, а также материалы нарушающие сетевой этикет или законы РФ. Ваш ip-адрес записывается.


QAIX > PHP web-programmingGo to page: 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | next »

see also:
Re: Preloading and switching images ...
static menu on the right
pass tests:
see also:
Hy my friends. I am Ehsan I am...
How to rip DVD, convert video, transfer…

  Copyright © 2001—2010 QAIX
Идея: Монашёв Михаил.
Авторами текстов, изображений и видео, размещённых на этой странице, являются пользователи сайта.
See Help and FAQ in the community support.qaix.com.
Write in the community about the bugs you have noticedbugs.qaix.com.
Write your offers and comments in the communities suggest.qaix.com.
Information for parents.
Пишите нам на .
If you would like to report an abuse of our service, such as a spam message, please .
Если Вы хотите пожаловаться на содержимое этой страницы, пожалуйста .