After validation, i got error and return back to :action = :new.
Some field on form already filled, so i want to keep them filled afterr error message too.
How it can be done?
Thanks.
I have an ASP pg with a formview list control on it that hooks up to a sql database customer table
I want to access the customer name outside the form.
How do I:
A) access the bound text box in the form view template? Something like Text1.text=formview1.customername.text (that doesn't work but that's the kinda thing)
B) access the database field in the table that the sqlsource connects to to feed the formview
Really appreciate the help. I bet it's easy to do but I'm just not getting there.
I have an ActiveRecord::Base class which needs to have a field that is automatically generated when a new instance is made. How should I go about doing this? By defining an initialize function?
class Thing < ActiveRecord::Base
# 'special' (integer) needs to be set to lowest unused number (above 0)
# considering that random rows will be removed via other processes
end
This is as far as I've got! Any ideas?
hi every one, this may be a basic thing, but i couldn't find an answer by serching internet.
I have created a simple button - Istance name = "btnsample"
and there are two layers
layer 0- button design with rollovers -
layer 1- dynamic text field - instance name = "txtbtnlabel"
btnsample.txtbtnlabel.text = "new button label;
but it's giving followin error :-119:Access of possible undefined propety txtbtnlabel through a reference with static type flash.display:simpleButton.
how to solve this problem?
I'm making a webapp, and I'd like an input field to show the Iphone's number keypad.
I understand that type=number will make the keypad show the way I'd like.
The trouble is that type=number does not support placeholder text. So if I would like this:
Expiration Date:
[eg: 2010]
I can not get it to work, and also show the right keyboard.
Is there a way to force the iphone keyboard into number mode without using the number input type?
i have a table called Cars and the primary key of the table is 'id'. I also have a field called 'name'. I would like to make sure no one enters the same name twice even though it wont break my db integrity.
what is the best way of doing this?
When we have a column that will store a username that will only accept letters and numbers we always do validation on this input field using javascript or even server validation from code .. but i want to know if is there any way that can allow me make this validation on the Table column itself even some one try to enter data from any place it don't accept and throw exception ?
Using hibernate with annotations, i want a one-many relationship to be sorted by the 'created' field on the 'many' table.
So far i've got this, which always ends up in a random order:
// The notes
@OneToMany
@JoinColumn(name="task_id")
Set<TaskNote> notes;
public Set<TaskNote> getNotes() {return notes;}
public void setNotes(Set<TaskNote> notes) {this.notes = notes;}
hi,
can I collapse the field in my edit-content page in Drupal ?
For example, at the bottom of the page Revision Information, URL Path Settings, Authoring Information etc are collapsed.
I would like to have this functionality for the CCK Fields as well.
thanks
this code is from the demo of modal confirmation from jquery's site.
<script type="text/javascript">
$(function() {
$("#dialog").dialog({
bgiframe: true,
resizable: false,
height:140,
modal: true,
overlay: {
backgroundColor: '#000',
opacity: 0.5
},
buttons: {
'Yes': function() {
$(this).dialog('close');
},
'No': function() {
$(this).dialog('close');
}
}
});
});
</script>
<div class="demo">
<div id="dialog" title="Empty the recycle bin?">
<p><span class="ui-icon ui-icon-alert" style="float:left; margin:0 7px 20px 0;"></span>These items will be permanently deleted and cannot be recovered. Are you sure?</p>
</div>
<!-- Sample page content to illustrate the layering of the dialog -->
<div class="hiddenInViewSource" style="padding:20px;">
<p>Sed vel diam id libero <a href="http://example.com">rutrum convallis</a>. Donec aliquet leo vel magna. Phasellus rhoncus faucibus ante. Etiam bibendum, enim faucibus aliquet rhoncus, arcu felis ultricies neque, sit amet auctor elit eros a lectus.</p>
<form>
<input value="text input" /><br />
<input type="checkbox" />checkbox<br />
<input type="radio" />radio<br />
<select>
<option>select</option>
</select><br /><br />
<textarea>textarea</textarea><br />
</form>
</div><!-- End sample page content -->
</div><!-- End demo -->
<div class="demo-description">
<p>Confirm an action that may be destructive or important. Set the <code>modal</code> option to true, and specify primary and secondary user actions with the <code>buttons</code> option.</p>
</div><!-- End demo-description -->
can anyone tell me how to edit the action for the buttons? when yes is clicked i want to be redirected to test.php and when i hit no i want to be redirected to another page.
My code does not update the thread field. It is null. Anyone have any ideas?
INSERT INTO [Messages]([Sender], [Receiver], [Job_Number], [Subject], [MessageText], [DateSent])
VALUES(@Sender, @Receiver, @Job_Number, @Subject, @MessageText, @DateSent)
SET @ThreadID = SCOPE_IDENTITY()
UPDATE [Messages]
SET Thread = @ThreadID
WHERE MessageID = @ThreadID
Hi-- I have a UK date in the format "06/Apr/2010 13:24" that I need to insert into a mysql db date field.
The PHP strtotime function can't handle this string-- has anyone got any ideas other than writing a custom function?
Thanks!
hi,
I developed a webapplication,Now i want to create Rss feeds for my website.
In my application i have a module call Film news, which contain the latest news of the film stars. Now i want to create rss feeds for that module. the news contains title and description. Can you help me how can i create rss feeds for my application. Tahnks in advance.
I have an array of field names. I would like to use those to populate the keys of another array, which will have empty values as default. Is there a single command I can do this with?
Hi everyone,
I have a simple text_field in my form where a user enters a time in minutes, i.e. 60.
How can I multiply that number by 60 before saving the form, such that the database stores the number in seconds?
Then, how do I reverse that and show the field in minutes on another view?
Thank you!
I have a large number of rows that I would like to copy, but I need to change one field.
I can select the rows that I want to copy:
select * from Table where Event_ID = "120"
Now I want to copy all those rows and create new rows while setting the Event_ID to 155. How can I accomplish this?
i am connecting to a mysql database through excel using odbc
what does this line do?
Set rs = oConn.Execute("SELECT @@identity", , adCmdText)
i am having trouble updating the database:
With rs
.AddNew ' create a new record
' add values to each field in the record
.Fields("datapath") = dpath
.Fields("analysistime") = atime
.Fields("reporttime") = rtime
.Fields("lastcalib") = lcalib
.Fields("analystname") = aname
.Fields("reportname") = rname
.Fields("batchstate") = "bstate"
.Fields("instrument") = "NA"
.Update ' stores the new record
End With
it is ONLY updating .Fields("instrument") = "NA", but for all other fields it is putting NULL values
i have date in dd/mm/yyyy format. how can i store it in databse, if i fant to do some operations on them after?
for example i must find out the rows, where date > something
what type i must set to date field?
thanks
I'm able to retrieve the URL of a publisher only if their URL is in the title or the description using regular expression in linkshare's coupon API but in doing so, that leaves me with a lot of publishers not having a reference to their website which I need for the type of site that I am building.
I was wondering if anyone else knows a way to reference the publishers URL preferably by their publisher ID or some other way?
In one of my HTML page dynamically loading some file field while clicking a button like follows
$('#add').click(function(){
$('#files').append('<input type="file" class="myfile" name="myfile" />');
});
My question is how to "bind" newly added element to HTML page so that I can access like
$('.myfile').change(function(){
// Code Here
});
I am asking this because
$('.myfile').live('change',function(){
// Code here
});
not working in all browsers , expecially IE
Please help thanks
Hi guys,
I would like to know how have I do to add a field in the customer administration at system-configuration-Customer settings panel.
Have I create the system.xml file from the core and paste in the local folder with the same path?
and have I maintain all the content of the file or I can write only the portion interested?
thanks
Why is that when I search a row in my database, it ended up 0 results? In fact, there are rows that meet my search criterion when I view them manually, but the search button doesnt work as it is. Heres how
you can see there are rows that have '0000-00-00 00:00:00' in them, but when I used the search feature, it ended up like this:
take note that Im entering it in the right field which is 'AcctStopTime'.
TIA
I'm trying to build a pager where it's just Next / Previous buttons that call a jquery function that post a JSON request. Inside the function, the current page "index" is retrieved from a hidden field and passed to the controller. Inside the controller, I reset the index if I'm on the last page of data. How would I pass the new index value back to the view? Or is there a better way to do what i'm trying to do?
Thanks
I have some doubt as follows
We are UPDATING a field in SQL and ALTER the row also.After giving the COMMIT command the system is crashed.Wat will happen to the commands given,whether it will UPDATE and ALTER the table r not?
Hi
In my mode I am selecting a field as
$query1 = $this->db->query("SELECT dPassword
FROM tbl_login
WHERE dEmailID='[email protected]'");
How to return dpassword as a variable to my controller
I tried this way return dpassword;