if(strlen($text ) > 200)
{
$textdisplaylis t = '<div>'.substr( $text,0,200).'< br><a href="#">Read More</a></div>';
}
else
{
//no point of having read more button here cuz there nothing more to read :)
$textdisplaylis t = '<div>'.$text.' </div>';
}
User Profile
Collapse
-
The actual subquery is function, which uses the "coalesce" function to return a comma separated list of organizations belong to that user. Therefore, it is not really possible to perform an inner join.Leave a comment:
-
Filter Scalar Subquery
I've spent most of the day trying to research but still not able to find the answer. When trying to run the code below, I get an error message saying that "new_user_n ame" doesn't exist. The code below run correctly without the last filter (WHERE new_user_name = 'a'). Similar code work just fine using MySQL but I can't understand why SQL Server return an error message. Any thought on this?
Code:SELECT id, first_name,
-
It does nothing but print the text.
Are you trying to create an object and append to the page or something?Leave a comment:
-
It looks like you are trying grab content on client computer. I don't believe it's possible to do that. You'll probably need to upload the file to your web server, then process the reading from there. Once you're done, you can just remove that file from the server. Don't forget to include Server.MapPath( filename)Leave a comment:
-
Thank you Plater,
It seems like the only cookie we need to send with the request is "test_cooki e". I've spent nearly 2 full days attempting to resolve this problem but no luck. I was about to the form inside a hidden iFrame and use javascript to trigger the button click event. This is a huge finding. Once again, thank you Plater.Leave a comment:
-
Yeah I've used this approach many and seemed to work fine. I tried to upload around up 30 files before. I think it might become problematic if you try to upload a bunch of large files.
I attached a quick demo (written in C# VS 2005). I didn't retrieve the file upload control data on postback so it doesn't hold it value. Remove the .zip extension and extract it as a rar file....Leave a comment:
-
You can use Javascript to create dynamic fileupload control (no limit)
In the .Net code, use the foreach loop to go through each of file in the File collection and do the upload.Leave a comment:
-
This is a hard problem. It is easier to add dynamic textbox using javascript which returns false to prevent postback; otherwise, you'll have to recreate these textboxes during postback if handling by .NET button control. Basically, in .NET, when the button is triggered, create the textbox and unique name/id to each of these textbox before adding to the form. You'll need to find a way to remember the number of created textbox, so you can re-create...Leave a comment:
-
HttpWebRequest Failed to enable cookie
I have done ton of researches but haven't been able to find a the solution for this problem. I attempted to auto-login into facebook when the page is load. However, I kept getting the error "Cookies are not enabled on your browser. Please adjust this in your security preferences before continuing." Base on MSDN documentation, we can just enable cookie by creating the CookieContainer object; however, I am not so sure what else could have...Last edited by Frinavale; Jul 30 '09, 07:59 PM. Reason: Please post code in [code] ... [/code] tags. Added code tags. -
Split the the email list into array
Usually when I encounter problem like this, I split the list of email in array and add them individually.
dim arrEmails as string() = strEmailList.sp lit(";")
Dim str as string = ""
foreach str in arrEmails
mail.to.add(str .trim())
next
Don't know why you add to the To field, but you can do mail.CC.add(... )...Leave a comment:
-
Global.asax does not fire method when loading static pages
Hi Everyone,
I have encountered this problem that I am not able to figure out. Please drop me some lines if you have any idea how to solve this issue. I have a global.asax file in my web site. It works fine as I wanted when loading aspx file; however, I have some static page in the same directory such as html and htm page. These page also load correctly and the global.asax file does fire when executing my .net development environment.... -
Javascript: Window.reload brings up Warning Message
Hi everyone,
I have a javascript function that basically has window.reload() to refresh the page. When this function execute, sometime it shows the warning message like "This is will repost the data....If this is a transaction, click cancel". The warning message appears to be show up randomly even on the same page with same data. Anyone know why and when does it show up? -
Response.Redire ct("default4.as px?roll="+TextB ox1.Text);
Response.Redire ct("default4.as px?name="+TextB ox2.Text);
}
FORM2 CODE--
protected void Page_Load(objec t sender, EventArgs e)
{
Label1.Text = Request.QuerySt ring["roll"].ToString();
Label2.Text = Request.QuerySt ring["name"].ToString();
}
====
Response.Redire ct("default4.as px?name="+TextB ox2.Text);...Leave a comment:
-
Check to my sure the the connectionstrin g in web.config is correct. Usually, that is the most common problem during web deployment. What kind of error are you getting? If you can't see the error , add this tag between <system.web></system.web> in the web.config file
<customErrors mode="Off"/>Leave a comment:
-
ASP.NET: CSS disappear after redirect from Global.asax
Protected Sub Application_Beg inRequest(ByVal sender As Object, ByVal e As System.EventArg s)
Dim strPath As String = HttpContext.Cur rent.Request.Pa th()
Dim cookie As HttpCookie = HttpContext.Cur rent.Request.Co okies("MyCookie Name")
' Handle if cookie not exist
If cookie Is Nothing Then
' Redirect to login page if cookie doesn't exist... -
ASP.NET Drop Down Listbox doesn't work in Opera Browser
I've been trying to figure out this problem for so long but no luck. The problem is that I have a ASP.NET Drop Down Listbox with a few item in there, and whenever I select an item from the listbox, I want to display its value in a label. The problem is that this code work properly in both IE and Firefox but not OPERA. It seems like Opera browser doesn't suppose the autopostback attribute of the drop down list. So, it doesn't do anything when I select... -
Wrong button.click function is trigger when press Enter key on textbox
I tried to use javascript to trigger up the button click function when user press enter key from the textbox. This function work fine with a single button click such has login page. However, if the page has multiple button such login page with a search function somewhere around, then it's not respond properly. I have attached a brief example of two text boxes and two button. When ever a key is press on textbox one, I want to trigger button1.click,...
No activity results to display
Show More
Leave a comment: