473,403 Members | 2,323 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,403 software developers and data experts.

Undefined variable: name

path is in which error is shown xampp is installed in d drive in my system
Undefined variable: name in D:\xampp\htdocs\phonereporting\application\views\s cripts\student\StudentFormVS.phtml on line 59
error here is tag i cannot retrieve name value from database

pls help me form name is StudentFormVS.phtml how to incluse one field value to this form
Expand|Select|Wrap|Line Numbers
  1. <body onload=" document.getElementById('firstname').focus();">
  2. <form name='studentform' method="post" action="<?php echo $this->element->getAction(); ?>">
  3.     <div class="adb-1-2std">
  4.     <!--Content Starts-->
  5.         <!--Course details-->
  6.         <div class="ads-5N">
  7.             <div align="right" class="td ads-5-1">&nbsp;</div>
  8.                 <div align="right" class="td ads-5-2">First Name<span class="Req gen-87">*</span></div>
  9.                 <div align="left" class="ads-5-3"><?php echo $this->element->firstname; ?></div>
  10.                 <div align="right" class="ads-5-4">Surname<span class="Req gen-87">*</span></div>
  11.                 <div align="left" class="ads-5-3"><?php echo $this->element->surname; ?></div>
  12.                 <!-- Start First Name error !-->
  13.                           <?php $errorfn = $this->element->firstname->getMessages();
  14.                                 $errorsn = $this->element->surname->getMessages();
  15.                               if(!($errorfn == null && $errorsn == null)){ ?>    
  16.                               <div align="left" class="ts-5-7">
  17.                         <?php foreach ($errorfn as $value ) {
  18.                                     echo $value;
  19.                             }
  20.                         ?>
  21.                     </div>
  22.                 <!-- Ends First Name error !-->
  23.                 <!-- Start Surname error !-->
  24.                     <div align="left" class="ts-5-71" >
  25.                           <?php $errorsn = $this->element->surname->getMessages();
  26.                             foreach ( $errorsn as $value ) {
  27.                                 echo $value;
  28.                             }
  29.                             echo "</div>";
  30.                          }
  31.                         ?>
  32.                 <!-- Ends Surname error !-->
  33.                 <div align="right" class="td ads-5-6">Supervisor Name</div>
  34.                 <div align="left" class="ads-5-7"><?php echo $this->element->supervisorname; ?></div>
  35.                 <div align="right" class="ads-5-8">Employee No</div>
  36.                 <div align="left" class="ads-5-7"><?php echo $this->element->employeeno; ?></div>
  37.                   <!-- Start Enter Employee No error !-->
  38.                       <div align="left" class="ts-5-71">
  39.                           <?php $errors = $this->element->employeeno->getMessages();
  40.                             foreach ( $errors as $value ) {
  41.                                 echo $value . '<br/>';
  42.                             }
  43.                         ?>
  44.                       </div>
  45.                 <!-- Ends Enter Employee No error !-->
  46.  
  47.                 <div class="gen-88"></div>
  48.             </div>
  49.  
  50.             <div class="ads-6Std">
  51.                 <div class="td band">
  52.                 <div class="Add_btn"><input type="button" value="Add" class="button"/ onclick="window.open('/student/pharmacy','','width=790,height=500,left=180,top=140,scrollbars=yes');"></div>
  53.                 <div class="Add_crs2" align="left"><strong >&nbsp;Pharmacy&nbsp;</strong>
  54.  
  55.                 </div>
  56.              </div>
  57.                     <div class="Add_Crs1">
  58.                         <?php echo $this->element->branches; ?>
  59.                         <?php $this->element->$name ;
  60.                         ?>
  61.  
  62.                     </div>
  63.                 <div class="gen-88">&nbsp;</div>
  64.             </div>
  65.  
  66.             <div class="ads-7">
  67.                 <div class="td band">
  68.                  <div class="Add_btn"><input type="button" value="Add" class="button"/ onclick="window.open('/student/course','','width=790,height=500,left=180,top=140,scrollbars=yes');"></div>
  69.                  <div class="Add_crs2" align="left"><strong >&nbsp;Course</strong></div>
  70.                 </div>
  71.  
  72.                 <div class="Add_Crs">
  73.                    <div class="Add_Crs1">
  74.                     <?php echo $this->element->courses; ?>
  75.                     </div>                    
  76.              </div>
  77.              </div>
  78.              <div ></div>
  79.             <div class="ads-7">&nbsp;
  80.             <div class="td band"></div>
  81.             </div>
  82.             <div class="ads-8">
  83.                 <div align="center" class="adc-6-1">
  84.                     <input type="submit" value="Save" class="button"/>&nbsp;&nbsp;
  85.                     <input type="reset" value="Reset" class="button"/>&nbsp;&nbsp;
  86.                     <input type="button" name="cancel" value="Cancel" onclick="javascript:window.location='/student/list'" class="button"/>
  87.                 </div>
  88.                 <div class="gen-88"></div>
  89.             </div>
  90.  
  91.         <!--Course details ends-->
  92.          <?php echo $this->element->id; ?>
  93.          <?php echo $this->element->addedBranch; ?>
  94.          <?php echo $this->element->addedCourse; ?>
  95.  
Nov 10 '11 #1
1 3283
zorgi
431 Expert 256MB
To me that looks like ZF view script. View scripts are often used if form is to complex for decorators. To add anything to the form you should first locate and edit class that uses this view script and than style it within view script.

StudentFormVS.phtml is not name of the form but view script name.
Nov 10 '11 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Dan Finn | last post by:
OpenBSD 3.2 Apache 1.3.26 PHP 4.3.4 PHP-Nuke 6.9 getting these in the apache error log: Sun Nov 16 20:20:16 2003] PHP Notice: Undefined variable: HTTP_USER_AGENT in...
4
by: Chris Beall | last post by:
If you want your code to be bulletproof, do you have to explicitly check for the existence of any possibly-undefined variable? Example: window.outerHeight is defined by some browsers, but not...
2
by: josel119 | last post by:
Hi everyone, Im a php newbie jejeej . Im getting the following error undefined variable at line 19 , I verified the php.ini and I dont know what else I can do. Im working on IIS with windows...
2
by: Reggie | last post by:
am trying to create a a upload file.am uploading files ok but i recieve this message. Notice: Undefined variable: uploaded_size in /home/fhlinux169/c/ clashoff.co.uk/user/htdocs/upload.php on...
5
by: siyaverma | last post by:
Hi, I am new to php, i was doing some small chnages in a project developed by my collegue who left the job and i got the responsibility for that, After doing some changes when i run it on my...
4
by: cyberlei | last post by:
hi all, I`m getting this error Notice: Undefined index: user in c:\inetpub\wwwroot\login.php on line 96 Notice: Undefined variable: message in c:\inetpub\wwwroot\login.php on line 101 Could...
2
by: norwichchris | last post by:
hi, I am having serious trouble with my PHP Postcard script. The error message i get is: Notice: Undefined index: Notice: Undefined variable Basically it does not send out the scripts at...
1
by: bob johnson | last post by:
Notice: Undefined variable: db_host in C:\wamp\www\cbmall\index.php on line 7 Notice: Undefined variable: db_user in C:\wamp\www\cbmall\index.php on line 7 Notice: Undefined variable: db_pass...
4
by: chin Tang | last post by:
Anyone help me check my coding.The error will be undefined variable of "$ptitle". <textarea name="ptitle" cols="100" rows="3" class="txt_blacknormal" id="ptitle"><?php echo $ptitle; ?></textarea>...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.