Jump to content

dev

Members
  • Content Count

    42
  • Joined

  • Last visited

Community Reputation

1 Neutral

About dev

  • Rank
    Newbie
  • Birthday 02/02/1980

Contact Methods

  • Website URL
    http://www.twipra.com
  • ICQ
    0

Profile Information

  • Location
    Tripura
  • Interests
    web designing
  1. Ok, let me write to them. thanks :-)
  2. Dear frenz, please share some ideas here. for some reason i have to run 64bit iis in 32bit mode which is working fine until i tried to access mysql database through odbc driver 5.1as my OS is 64bit, so i had to install 64bit odbc as well. now 32bit iis is throwing ODBC Drivers error '80004005' ([Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified) but tuning back the iis to 64bit performs the task well. Any ideas to make it work in 32bit mode?with thanksdev
  3. Sir,i have an arrays likea=1b=42c=5d=4e=11f=7 is it possible to sort them like b,e,f,c,d,a where the highest value kept on top.with thanks
  4. Sir, i was playing with split function and suddenly a question was raised, e.g. dim a,txttxt="a b c d e f g h i j"a=split(txt," ")for i=0 to 9 response.write a(i) & "<br>"next it will display txt from a to j, is it possible to display them j to a? if yes the how?your help is highly obliged.
  5. dev

    Create div dynamically

    Sorry for the confusion. yes i want to hide (css property - display:none) a div that i have created with function createDiv(); Actually i want to incorporate this functionality in user comment section. as users post their comments, this java functionality will show their post through ajax. so i want to keep the option to delete the post too by css property display:none and i will call a remote page to actually delete the post through ajax. thats why i wish to call a function through onclick event but am confused. please help.
  6. dev

    Create div dynamically

    Sir one more problem, kindly get me work the function cl(); here am attaching the code: ---------------- <html><head> <title>Javascript Create Div Element Dynamically</title> <style type="text/css"> .dynamicDiv { width:200px; height:100px; border:solid 1px #c0c0c0; background-color:#e1e1e1; font-size:11px; font-family:verdana; color:#000; padding:5px; }#ht{border:1px solid red;padding:6px} </style> <script type="text/javascript" language="javascript">var myText="<table><tr><td> <\/td><\/tr><tr><td>some text<\/td><\/tr><\/table>" function cl(){ } function createDiv(){var did="";var possible="abcdefghijklmnopqrstuvwxyz";for( var i=0; i < 4; i++ ){did +=possible.charAt(Math.floor(Math.random() * possible.length));}var divTag = document.createElement("div");divTag.id = did;divTag.className = 'setm';divTag.setAttribute('style','text-align:center')divTag.style.border = "1px solid #ccc";divTag.innerHTML = myText;par=document.getElementById('ht');par.insertBefore(divTag,par.firstChild)}</script></head><body><input id="btn1" type="button" value="create div" onclick="createDiv();" /> <div id="ht"></div> </body></html>---------------
  7. dev

    Create div dynamically

    eTianbun :-)Thank you so much :-) its working perfectly.
  8. Dear sir, I was trying to create a div element dynamically on top of another div(existing div) with javascript. I end up using these code: ------------- function createDiv(){var divTag = document.createElement("div");divTag.id = "div1";divTag.setAttribute("align","center");divTag.style.border = "1px solid #ccc";divTag.innerHTML = Date();document.getElementById("ht").appendChild(divTag);}--------------but this code creates div not on top but beneath. Kindly correct my code so that it will create div not beneath but on top.Your help is highly obliged.
  9. dev

    Server Info

    Hi, frensis it possible to know if a remote hosting server is running on 32/64 bit OS and a version of webserver?ASP/.netactually i have a component of 32 bit and want to install it in 64 bit... for that i need to know this info. please helpwith thanks
  10. dev

    Java Cookie

    Dear frens,Can u help me sorting this problem:in classic asp i write cookie as: Response.Cookies("ePortal")("ID")="blabla"and i read cookie values as: Request.Cookies("ePortal")("P12")now with javascript i know: document.cookie="ePortal"+"="blabla";now my question is - how can i create a cookie with keys using javascript as i did with asp?I will be thankful
  11. dev

    Php To Asp

    Sir,Please help me to convert this php code to asp<?php$result = array(); $result['time'] = date('r');$result['addr'] = substr_replace(gethostbyaddr($_SERVER['REMOTE_ADDR']), '******', 0, 6);$result['agent'] = $_SERVER['HTTP_USER_AGENT']; if (count($_GET)) { $result['get'] = $_GET;}if (count($_POST)) { $result['post'] = $_POST;}if (count($_FILES)) { $result['files'] = $_FILES;} if (file_exists('script.log') && filesize('script.log') > 102400) { unlink('script.log');} $log = @fopen('script.log', 'a');if ($log) { fputs($log, print_r($result, true) . "\n---\n"); fclose($log);} $error = false; if (!isset($_FILES['Filedata']) || !is_uploaded_file($_FILES['Filedata']['tmp_name'])) { $error = 'Invalid Upload';} if ($error) { $return = array( 'status' => '0', 'error' => $error ); } else { $return = array( 'status' => '1', 'name' => $_FILES['Filedata']['name'] ); // Our processing, we get a hash value from the file $return['hash'] = md5_file($_FILES['Filedata']['tmp_name']); // ... and if available, we get image data $info = @getimagesize($_FILES['Filedata']['tmp_name']); if ($info) { $return['width'] = $info[0]; $return['height'] = $info[1]; $return['mime'] = $info['mime']; } } if (isset($_REQUEST['response']) && $_REQUEST['response'] == 'xml') { // header('Content-type: text/xml'); // Really dirty, use DOM and CDATA section! echo '<response>'; foreach ($return as $key => $value) { echo "<$key><![CDATA[$value]]></$key>"; } echo '</response>';} else { // header('Content-type: application/json'); echo json_encode($return);}?>
  12. dev

    Php To Asp

    Hi, am afraid if i am posting in right cat. can anyone please translate this php code to asp<?php $id = $_GET['sessionId']; $id = trim($id); session_name($id); session_start(); $inputName = $_GET['userfile']; $fileName = $_FILES[$inputName]['name']; $tempLoc = $_FILES[$inputName]['tmp_name']; echo $_FILES[$inputName]['error']; $target_path = 'c:\\upload\\'; $target_path = $target_path . basename($fileName); if(move_uploaded_file($tempLoc,$target_path)) { $_SESSION['value'] = -1; }?>I will be thankful
  13. hi,I am constructing a small RTE for my forum and finally stucked in last turn. i am using iframe to do rte job done and its really working smoothly but didn't get any idea on how to retrieve the edited html values and store in database. so to do that i used an hidden input.<form name="myform<iframe name="myRTF" id="myRTF" class="EditControl" frameborder="0" onblur="UpDate()"></iframe><input type="hidden" id="readtxt" name="htmlval" /></form>the idea is to update the myform.htmlval.value with window.frames["myRTF"].document.body.innerHTML; this code work fine in IE6 and hopefully IE7 too but Opera don't support it. so i tried contentdocument.body.innerHTML too but nothing happened. this rte do not use textarea.i am not so good in java. so dear experts: is there any other way to retrieve the html values or help me to understand and solve the problem. i really din't understand why opera is not supporting window.frames["myRTF"].document.body.innerHTML?hope someone in this forum will save me :)with thanks
  14. dev

    how to save cropped image

    i am getting this error msg:Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Runtime.InteropServices.ExternalException: A generic error occurred in GDI+.Source Error: Line 17: g.DrawImage(i, New Rectangle(0, 0, 400, 400), New Rectangle(0, 0, 200, 200), unit)Line 18: Response.ContentType = "image/jpeg"Line 19: b.Save("hh.jpg", ImageFormat.Jpeg)Line 20: Line 21: b.Dispose()
  15. hi,please help me, i am stucked here. i am using the following code to crop image to a certain with and height but how to save the cropped image? i am new to .net<%@ Page Language="vb" Debug="true" %><%@ import namespace="system.drawing" %><%@ import namespace="system.drawing.imaging" %><%@ import namespace="system.drawing.drawing2d" %><%Dim strFilename as StringDim i as System.Drawing.ImagestrFilename = Server.MapPath("horse.jpg")i = System.Drawing.Image.FromFile(strFilename)Dim b As New System.Drawing.Bitmap(400, 200, PixelFormat.Format24bppRgb)Dim g as Graphics = Graphics.FromImage(B)g.Clear(Color.Blue) Dim unit = GraphicsUnit.Pixelg.DrawImage(i, New Rectangle(0, 0, 400, 400), New Rectangle(0, 0, 200, 200), unit)Response.ContentType = "image/jpeg"b.Save(Response.OutputStream, ImageFormat.Jpeg)b.Dispose()g.Dispose()i.Dispose()%>Please tell me, with thanks
×
×
  • Create New...