|
George2 wrote:
How to add a user defined HTTP header field to a HTTP
response header? Are there some sample codes?
Did you add the HTTP HEader field in IIS first?
Go into IIS, right click a web, properties, HTTP Headers and then click the Add button. You should then, once setup, be able to use the header.
Paul Watson Bluegrass Cape Town, South Africa
Ray Cassick wrote:
Well I am not female, not gay and I am not Paul Watson
|
|
|
|
|
Thanks, Paul pal!
Maybe you mis-understood my idea.
I wrote a web server by myself and it is able to receive
special header fields. So, I want to send a special header field
to my web server.
So, how can I send an HTTP request with a special header field?
Do you have any ideas?
Cheers,
George
|
|
|
|
|
George2 wrote:
I wrote a web server by myself
Hmm in that case I do not know. I would assume the code you posted up above would work.
Sorry I cannot help
Paul Watson Bluegrass Cape Town, South Africa
Ray Cassick wrote:
Well I am not female, not gay and I am not Paul Watson
|
|
|
|
|
I have a 3-box network at home... a Win2k Server (used as a file server and IIS/SQL host), a desktop running Win2k Server and a laptop running Win2k Server (used to have Pro).
I've been debating on moving the laptop to WinXP Pro but my concern has been it's capabilities as a development platform. The more and more I see screenshots and attend seminars, the more I see WinXP. I love the look and feel, just concerned about using it as a development platform (also to watch DVDs). I'm toying wiht the idea of putting WinXP on it and if I don't like it, just putting Win2K Pro back on (need those power managment features).
Does anyone have any opinions or input about using WinXP Pro on a laptop when the primary use of the laptop is development (VS.NET/PhotoShop/Illustrator/OfficeXP)? What about WinXP Pro's power managment features on a laptop?
Thanks,
-AC
|
|
|
|
|
Andrew Connell wrote:
Does anyone have any opinions or input about using WinXP Pro on a laptop when the primary use of the laptop is development (VS.NET/PhotoShop/Illustrator/OfficeXP)? What about WinXP Pro's power managment features on a laptop?
Well I use WXP all the time and it is great. A co-worker uses WXP on a laptop and has had no problems (battery life remained the same from W2K to WXP.)
I also do VS.NET, Photoshop, Illustrator and Office XP btw.
Ray Cassick
|
|
|
|
|
I currently use WinXP Pro on my desktop and my laptop. I love it, and haven't noticed anything too quirky. I currently have a Dell laptop on order, and will be putting XP Pro on it by choice as well. Of course, the new ones come with the mobile processors and intelligent batteries, so I don't really have to worry about battery length so much, but on my old Toshiba I haven't noticed anything untoward. On my new one I will be putting a dual boot with Red Hat, but then I'm just inclined to play about, and any laptop with 512 ram and a P4 2.4Ghz cpu is a proper dev machine as far as I'm concerned.
WinXP rocks with Dev, I find it quite surprising how resistant to change dev's are, considering they constantly work with cutting edge technology. Go for it!
We don't need a thinker! We need a do-er! Someone who will act first, without considering the consequences. - Homer J Simpson
|
|
|
|
|
Have WinXP Pro on my laptop and found no problems. I use VS6 there though. My desktop has Win2k Pro with WS.NET installed
Also watching DVDs on laptop everytime, works just fine, even enough battery to finish the movie
Philip Patrick
Web-site: www.stpworks.com
"Two beer or not two beer?" Shakesbeer
|
|
|
|
|
Hi
I am trying to set a session variable in javascript function with the values that are passed as parms to the function from my asp. here is how i am doing..
From my asp code
loop thru the resultset
do while not re.eof
'i cannot set the session variables here coz there may be 1000 records, i want
'to create a session variable only for the clicked item so am using javascript.
<a href="javascript:runthis('mbrid','mbrname');"> Name</a>
loop
Now in my javascript code
function runthis(id, nm){
//now i want to save these two parms in session variables
//this is how i am trying to do
<%session("sessvar_id") %> + '=' + id;
<%session("sessvar_name") %> + '=' + nm;
document.frmsel.action='response.asp';
document.frmsel.submit();
}
but in the results page i couldnt read these values from the session variables..
can someone please help me to acheive this?
|
|
|
|
|
Daniel78 wrote:
can someone please help me to acheive this?
I am not 100% sure what you are trying to do but if you are trying to set an ASP Session variable using JavaScript on the client side, you cannot. Client Side and Server Side are removed from each other.
|
|
|
|
|
You can place ASP variable values into Javascript variables, but not the other way around.
<%
'ASP section here
Dim Amount
'put session variable into local variable
Amount = session("Amount")
'end of ASP
%>
<% ' open ASP again %>
HTH.
We don't need a thinker! We need a do-er! Someone who will act first, without considering the consequences. - Homer J Simpson
|
|
|
|
|
Megan Forbes wrote:
You can place ASP variable values into Javascript variables
I have always thought that this simple concept is actually quite powerful and very useful (and on hingsight totally obvious.)
It is something I sometimes miss when doing Windows app. dev.
I have this written for new developers here:
ASP Web Dev Tip #32: Remember on the server side you can output virtually anything to the client side. What is sent back to the client is just text and nothing more, so use it!
|
|
|
|
|
Paul Watson wrote:
quite powerful and very useful
Too right - a lifesaver sometimes. The problem comes when people don't understand how the page loads (server first, client second) and try to put client values into server side values. A learning curve I guess
We don't need a thinker! We need a do-er! Someone who will act first, without considering the consequences. - Homer J Simpson
|
|
|
|
|
I have a datagrid that has one Template column and one button column.There is a RadioButtonList in Template column.I want when user click on button column,get which item is selected in radioButtonList of that row.I
overriden Item_Command of grid like this:
if(e.CommandName=="Vote")
{
RadioButtonList radio = (RadioButtonList)e.Item.FindControl("OptionsList");
Label2.Text = radio.SelectedIndex.ToString();
}
But it always show -1 and I can't get selected item!
Mazy
"If I go crazy then will you still
Call me Superman
If I’m alive and well, will you be
There holding my hand
I’ll keep you by my side with
My superhuman might
Kryptonite"Kryptonite-3 Doors Down
|
|
|
|
|
I have a user control that has a property which I want to bind it to a datasource.
QuestionID='<%# DataBinder.Eval(Container.DataItem, "QuestionID") %>'
But it seems that user control is not bindable.Is that True?
Mazy
"If I go crazy then will you still
Call me Superman
If I’m alive and well, will you be
There holding my hand
I’ll keep you by my side with
My superhuman might
Kryptonite"Kryptonite-3 Doors Down
|
|
|
|
|
Does the QuestionID property have a BindableAttribute ?
"There are no stupid question's, just stupid people."
|
|
|
|
|
leppie wrote:
Does the QuestionID property have a BindableAttribute ?
Oh,I don't think so.How can I make it Bindable?
Mazy
"If I go crazy then will you still
Call me Superman
If I’m alive and well, will you be
There holding my hand
I’ll keep you by my side with
My superhuman might
Kryptonite"Kryptonite-3 Doors Down
|
|
|
|
|
Mazdak wrote:
Oh,I don't think so.How can I make it Bindable?
[Bindable(true)]
public int QuestionID {get; set;}
"There are no stupid question's, just stupid people."
|
|
|
|
|
That doesn't help.Its User Control,not server control.Are you sure about it?
Mazy
"If I go crazy then will you still
Call me Superman
If I’m alive and well, will you be
There holding my hand
I’ll keep you by my side with
My superhuman might
Kryptonite"Kryptonite-3 Doors Down
|
|
|
|
|
Mazdak wrote:
That doesn't help.Its User Control,not server control.Are you sure about it?
It shouldnt be any different to a Server / Web Control (although I didnt think about that originally ) . Paste us your code for the property and maybe I help you further
"There are no stupid question's, just stupid people."
|
|
|
|
|
public int QuestionID
{
get { return questionID; }
set { questionID = value; }
}
I don't think its possible for user control.The control first render,then the binding happend.I guess.
Mazy
"If I go crazy then will you still
Call me Superman
If I’m alive and well, will you be
There holding my hand
I’ll keep you by my side with
My superhuman might
Kryptonite"Kryptonite-3 Doors Down
|
|
|
|
|
Mazdak wrote:
I don't think its possible for user control.
I started messing around with UserControls tonite, and I must agree with you (at least for now) .
You can however "manually" "bind" it at the page load event, erm I think, brain does not seem to function so well today
"There are no stupid question's, just stupid people."
|
|
|
|
|
You can!
Like this:
<uc1:UserDetails id="UserDetails1" runat="server"
Address='<%# DataBinder.Eval(ds1.Users[0], "Address") %>'
Username='<%# DataBinder.Eval(ds1.Users[0], "Username") %>'>
</uc1:UserDetails>
Address and Username is properties in the code-behind class.
[edit]eeek[/edit]
|
|
|
|
|
Could you please send me all your code?User Control and your aspx with its code-behind.
mazdakmansouri@hotmail.com
Thanks.
Mazy
"If I go crazy then will you still
Call me Superman
If I’m alive and well, will you be
There holding my hand
I’ll keep you by my side with
My superhuman might
Kryptonite"Kryptonite-3 Doors Down
|
|
|
|
|
Mazdak wrote:
Could you please send me all your code?User Control and your aspx with its code-behind.
Erm no, sorry
But like I said it quite easy. Just do what I said.
- Define a property (Username) in the code-behind class (LoginControl) like this:
public string Username { get { return userTextBox.Text;} {set {userTextBox.Text = value;}}
- In the ascx file, "bind" it like this:
<uc1:LoginControl id="LoginControl1" Username='databind expression' runat=server></uc1:LoginControl>
Have a look on MSDN at databinding on web forms aka late-binding.
I find it easier to just map the data from the dataset to the control at a page event.
Hope this helps
"There are no stupid question's, just stupid people."
|
|
|
|
|
Can anyone help me. I want to setup a feedback form in my site. That should send the results to a email automatically. Any idea... I am a biginer, so... need simple exaples or stuffs like that....
|
|
|
|