Jump to content

bdsafa

New Members
  • Posts

    4
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

bdsafa's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. yeah , two thumbs up for ManiacDan, you're the Man, i got it together.
  2. I exactly know that its a function, here is the datacorrection.php : function datacorrection(&$str) { include('utt.php'); $text = explode("\n", $str); $str = array(); foreach($text as $line){ $chars = utt::utt(utt::uttStringToArray($line), 'R'); $line = ''; foreach($chars as $char){ $line .= utt::unichr($char); } $str[] = $line; } $str = implode("\n", $str); } ?> and utt.php starts with a class named utt. you see?
  3. Yeah, loop , sorry about that by the way , i know that its only need to include once, but the way i need to use it is a little different, look : include_once('datacorrection.php'); $file = file("sampletxt.txt"); foreach ($file as $line) { $data = explode('|',$line); $title = $data[0]; datacorrection($title); echo $title; } you see? i can't simply put the class out of the loop. if i do, nothing will be corrected.
  4. Yo, everyone. I got a problem with the class i wrote for my coding, I need to use the class for every data that will show up. for that i used a 'for' cycle, but it seems i get only the first one of the cycle right. well the problem seems that the class can only be included once and for the rest, I got a header problem. Is there a way to actually use classes in a cycle? Thanks in Advance.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.