| Author | 
         | 
         
      
        
         
         Jeff U Groupie 
          
 
  Joined: 16 December 2007 Location: United States
 Online Status: Offline Posts: 58
          | 
        
         
          
           | Posted: 17 December 2007 at 8:07am | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
How can I lock the ability to change the "From" line.  I found the snip in function.js but I am not sure how to lock the entry abiity on the form.  .net version.
 
 Thanks
 Jeff
 
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         Andrew AfterLogic Support 
          
 
  Joined: 28 April 2006 Location: United States
 Online Status: Offline Posts: 1189
          | 
        
         
          
           | Posted: 18 December 2007 at 2:05am | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
To disable From field on compose message screen, you should change the following line in screen.new-message.js file (line 648):
 
Code: 
   
    
    
      
       | var inp = CreateChildWithAttrs(td, 'input', [['type', 'text'], ['class', 'wm_input'], ['size', '93'], ['maxlength', '255']]); | 
       
       | 
    
    | 
 
 
 replace with:
 
Code: 
   
    
    
      
       | var inp = CreateChildWithAttrs(td, 'input', [['type', 'text'], ['class', 'wm_input'], ['size', '93'], ['maxlength', '255'], ['disabled', 'disabled']]); | 
       
       | 
    
    | 
 
 
 
 Best regards,
 Andrew
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         Jeff U Groupie 
          
 
  Joined: 16 December 2007 Location: United States
 Online Status: Offline Posts: 58
          | 
        
         
          
           | Posted: 18 December 2007 at 7:17am | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
In the .net lite version?  I don't have any file with that name.
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         Andrew AfterLogic Support 
          
 
  Joined: 28 April 2006 Location: United States
 Online Status: Offline Posts: 1189
          | 
        
         
          
           | Posted: 19 December 2007 at 5:10am | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
Sorry, that was about Pro version.
 
 In the Lite version, you should modify functions.js file, line 740.
 
 Before the line:
 
Code: 
   
    
    
      
       | aCachePageElements[listc] = textfield; | 
       
       | 
    
    | 
 
 
 insert:
 
Code: 
   
    
    
      
       | if (listc == COMPOSE_MESSAGE_FROM) textfield.disabled = true; | 
       
       | 
    
    | 
 
 
 
 Best regards,
 Andrew
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         Jeff U Groupie 
          
 
  Joined: 16 December 2007 Location: United States
 Online Status: Offline Posts: 58
          | 
        
         
          
           | Posted: 20 December 2007 at 7:54am | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
The closest line I have to that is:
 aCachePageElements[listc] = textfield;
 and your code snip did not do anything to that function.
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         Jeff U Groupie 
          
 
  Joined: 16 December 2007 Location: United States
 Online Status: Offline Posts: 58
          | 
        
         
          
           | Posted: 20 December 2007 at 8:10am | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
Found the problem.  Needed to be:
 if ([listc == COMPOSE_MESSAGE_FROM]) textfield.disabled = true;
 
 Thanks
 Jeff
  
 
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         Jeff U Groupie 
          
 
  Joined: 16 December 2007 Location: United States
 Online Status: Offline Posts: 58
          | 
        
         
          
           | Posted: 20 December 2007 at 8:14am | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
Spoke to soon.  That just locked all entry out of the entire section.
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         Andrew AfterLogic Support 
          
 
  Joined: 28 April 2006 Location: United States
 Online Status: Offline Posts: 1189
          | 
        
         
          
           | Posted: 21 December 2007 at 3:10am | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
Is it the behavior you expected? If not, could you please describe how it behaves now and how you need it to behave?
 
 Best regards,
 Andrew
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         Jeff U Groupie 
          
 
  Joined: 16 December 2007 Location: United States
 Online Status: Offline Posts: 58
          | 
        
         
          
           | Posted: 22 December 2007 at 9:04pm | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
I would like the from line to either be hidden from change, or not changeable to the end user.
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         Alex AfterLogic Support 
          
  
  Joined: 19 November 2003
 Online Status: Offline Posts: 2207
          | 
        
         
          
           | Posted: 24 December 2007 at 8:40am | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
In the WebMail Lite, you should modify functions.js file, line 725. It seems [i] was lost in our previous code sample (the forum engine treated it as italic tag). Here is the correction:
 
 After the line:
 
Code: 
   
    
    
      
       | var mm_tr = m_table.insertRow(-1); | 
       
       | 
    
    | 
 
 
 
 insert (to hide the "From" line):
 
Code: 
   
    
    
      
       | if (listc[i] == COMPOSE_MESSAGE_FROM) textfield.disabled = true; | 
       
       | 
    
    | 
 
 
 
 or insert (to make the "From" line read-only):
 
Code: 
   
    
    
      
       | if (listc[i] == COMPOSE_MESSAGE_FROM) mm_tr.style.display = 'none'; | 
       
       | 
    
    | 
 
 
 
 
 Regards,
 Alex
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         Jeff U Groupie 
          
 
  Joined: 16 December 2007 Location: United States
 Online Status: Offline Posts: 58
          | 
        
         
          
           | Posted: 27 December 2007 at 7:09am | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
Thats what I was after, thanks.  The new version out yet?
 
 Jeff
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         Alex AfterLogic Support 
          
  
  Joined: 19 November 2003
 Online Status: Offline Posts: 2207
          | 
        
         
          
           | Posted: 27 December 2007 at 8:19am | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
WebMail Lite v4.1 went internal testing stage. We expected it to be released in January 2008.
 
 Regards,
 Alex 
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         maxline Newbie 
          
 
  Joined: 04 February 2008 Location: India
 Online Status: Offline Posts: 1
          | 
        
         
          
           | Posted: 04 February 2008 at 12:26pm | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
How do i Block the From Field in the Latest release
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         Andrew AfterLogic Support 
          
 
  Joined: 28 April 2006 Location: United States
 Online Status: Offline Posts: 1189
          | 
        
         
          
           | Posted: 05 February 2008 at 1:18am | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
Instructions are the same as in the second post of this topic, i.e. screen.new-message.js file, but line ~410 instead of 648.
 
 Best regards,
 Andrew
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         Jeff U Groupie 
          
 
  Joined: 16 December 2007 Location: United States
 Online Status: Offline Posts: 58
          | 
        
         
          
           | Posted: 14 March 2008 at 11:48am | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
Andrew, 
 How would I set the from field in WebMail Lite PHP to read only?
 
 Thanks
 Jeff
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         Andrew AfterLogic Support 
          
 
  Joined: 28 April 2006 Location: United States
 Online Status: Offline Posts: 1189
          | 
        
         
          
           | Posted: 15 March 2008 at 4:07am | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
The modifications described above for ASP.NET version of WebMail Lite (disabling From field) are correct for PHP version too.
 
 Best regards,
 Andrew
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   | 
      
        
         
         shashi_nsp Newbie 
          
  
  Joined: 01 March 2009 Location: Oman
 Online Status: Offline Posts: 6
          | 
        
         
          
           | Posted: 01 March 2009 at 10:47pm | IP Logged
		     | 
                    
            		  
           | 
           
          
           
  | 
           
          
 
Jeff U wrote: 
   
    
    
      
       How can I lock the ability to change the "From" line.  I found the snip in function.js but I am not sure how to lock the entry abiity on the form.  .net version.
 
 Thanks
 Jeff
  | 
       
       | 
    
    | 
 
  
 
 See the Line Num 738 & Change the From Filed Type to hidden.
 ----------------------
 tr = tbl.insertRow(RowIndex++);
             td = tr.insertCell(0);
             td.className = 'wm_new_message_title';
             td.innerHTML = ' ';
             WebMail.LangChanger.Register('innerHTML',  td, ' ', ' ');
             td = tr.insertCell(1);
             var inp = CreateChildWithAttrs(td, 'input', [['type', 'hidden'], ['class', 'wm_input'], ['size', '93'], ['maxlength', '255']]);
             inp.tabIndex = 1;
             this._fromObj = inp;
         | 
       
       
        | Back to Top | 
         
          
         | 
       
       
       
        |   |