Jump to content
xisto Community

veerumits

Members
  • Content Count

    88
  • Joined

  • Last visited

Everything posted by veerumits

  1. before multilevel feedback scheduling algorithm , we used only multilevel scheduling algorithm which was not so flexible, but this one uses separate queue for handling the processes , it automatically adjust the priority of the process.If the priority is high and the process will be alloted to lower priority queue, then automatically it can switch to the higher priority queue .for example, one queue may implement round robin algorithm the other may use first come first serve algorithm , the allocation is based on the type of process i.e the process is either of cpu bound or i/o bound etc....it is now used by generally all the operating system only because of its flexibility but it is some complex to understand .i have a full information regarding cpu scheduling algorithm, i will be highly thankful if i can help you .
  2. I want to add theme in our site. theme included Color, Graphics, resolution, and background images, Title, Heading, Links, menu bar Body color, text color etc.when user select the theme according to theme it takes changes, on whole of the page, could any one can suggest regarding this i dont have any idea how to be apply this on the web page. i design a website which have a standard design like header, footer, lefter, righter, and a body any change need according to the link its only reflect on the body so mostly change have in body of the page, i add a link to theme on the header. i want when user click on theme theme menu popup and select the theme when he/she apply it take effect on the page, i also design a code for dynamic change in css style sheet. according to theme different css will select but when i apply it is not working fine.so i request to all the member who reads this post and have any idea how to solve this problem, are welcome.thanks
  3. With all thanks to your advice and suggestion to me and also hope to you and to all to notice or point out my error in writing skill, i mean grammatical error in the post, your advice are most welcome, dear i dont know you but you are the member of Xisto so i think that you have relation with me as a member, and this is right place, where i think, we got all, what we hope. i am trying to improve my English sure it will come one day, you can also send me personal massage and i'll be very thankful to you.
  4. 1)many time programmer see that his code gone to in infinite loop what exactly happened behind the code even if he see that logical code is not in infinite loop. then why it look like the infinite loop. some time what happened the intermediate r is not working fine his code in infinite loop not your code in infinite loop so before making decision to change the code please stay for some time to execute the code of interpreter, sure if your logic is not in infinite loop then it execute as per your desire, so why we are not stay or wait because my mind is in infinite loop he taking more and more decision and result is same, when we cool my work is fine. what we expect with code it do as well. some time people are innocent to his work because due to pressure of work, family, money, future, etc. at that time what we should do go to the lonely place and make your mind cool after then do the work. really this is practical approach which is applied by to the programmer. 2) some time what we do with the code we use more loops and decision control in our code and so the execution time is increase and we thought that my code is in infinite loop but exactly what happened with the code its result come after some time when his cycle is complete.3)Some time we use jumping statement in code and there is a looping at that stage also execution time increase.overall i want to express the think that dont loose the control over the looping. your decision is as per you desire.thanks.
  5. If you follow these steps to Connect your PCs here I am also clear one thing that what is the use cross and straight cables and which you use for your purpose.The following diagram shows the Normal use of Crossed and Straight cables 1) <--Straight -->(Hub or Switch) -->Crossed<---(Hub or Switch) <---Straight --->(PC) 2) (PC) <-----Crossed ------>(PC) Important Notes: 1. We show Straight cables as Bold and Crossed as Italian. cable color can be anything you choose. 2. To avoid the need for Crossed cables if you have UPLINK ports on Hubs or Switches - these are specially designed to allow the use of a straight cable when connecting back-to-back Hubs or Switches. Crossed Cable Connection:- give the no. of both end same and joined as follows. One end RJ45 Male Other end RJ45 Male 1 3 2 6 3 1 4 * 5 * 5 * 4 * 6 2 7 * 8 * 8 * 7 * Straight Cable Connection:- One End Same As other End of RJ45, Color code is Optional if you choose for personal use. Pin No. conductor color 1 white and orange 2 Orange 3 white and green 4 Blue 5 white and blue 6 Green 7 white and brown 8 Brown In this way you can physically connected your both PC and if you want to share files use share file system wizard. To share the file. please dont think that this is perfect way to do this task have so many alternatives so you can use as per convenient. this is also need. thanks
  6. Can any one give the idea how to disable task manager and regedit from PHP code. i agree with VB code it is one kind of security task by the programmer.
  7. The service pack 2 have more secure patch with firewall security so i think if have possibility to use it to make the system secure from Microsoft windows xp. or can make secure from otherhand also but it is not reliable so i also using SP2. as most says that every SP should be use time to time otherwise you suffered ya this is correct if you are using older version than you are data is not secure so how to protect data from third party tool why we are not using SP this if free use for test. it is down loadable from the site. approx. size 250 mb. it not only protect from mal function but it also protect from unauthorized use of your PC.
  8. Windows coming version is looking cool as compare to previous version, but my statement in this regard is just waisting the time to learn new nonsense thinks which is not useful to every guys. if something more advance then i try it sure.
  9. The information here i post is just for my personal experience.To break the security is very easy task if people know your personal information from any source like accessing your personal system, give to use your personal system due to happening circumstances this is your majboori to give the system to use. or applying for any kind of subscription is also need your personal information and that information is sold.this is also a one kind of leakage your information with out any prior notice to you that i am going to sell your information to fulfill our requirement, any way i want to say that your information will change from personal to global so user are suffered so many kind of lack of security issue. if you are using passworded pen drive with a secure software that information can also be fetch by the security breaker with the help of automated software system. any kind of virus program can also destroy your files generate new unwanted files. even you are using security software this is happen because your personal information from any kind of source is leakage.
  10. i want to know that what is the difference between iteration and object overloading in PHP. i read that both are same object overloading is old name of iteration, but i have doubt so please any one can help in this regard what i know that : * Iteration :- Loop the object * used to Display property name and class value. * foreach loop used : - only used in array and object iteration. here i give example of iteration: <?phpclass abc{var $user="Raju"; var $city="Delhi";var $age= 25;}$obj=new abc;echo "<table border=1>";echo "<tr><td> property Name </td><td> property Value </td></tr>";foreach($obj as $p=> $x){ echo "<tr><td> $p </td><td> $x</td> </tr>"; }echo "</table>";?> output:- property Name property Value user Raju city Delhi age 25 every thing is fine but i am not fully understood this. how it works. what is the behavior of this iteration. how we can say that it is object overload. thanks
  11. The information regarding email validation is very helpful and clear my doubt. for this regard i use like this for email validation if (!preg_match("/^[^@]+@[^@]+\.[^@]/", $_POST['email'])) { $emailerror="E-mail address is invalid"; } and i think it most probability full fill requirement but it is issue of research. so please dont stop this topic till final stage.or final conclusion. it need some more advance code to perfectly validate the email. thanks.
  12. PHP 5, have magic method:-- The __autoload() Magic Method:- The __autoload() magic method get automatically called whenever you try to load an object of the class in which resides in separate file and even you have not included those files using any of these method include,require and include_once. but It is neccessary to use the filename as that of the class name. for example:- //file name: abc.php; <?phpclass abc{var $user="Raju";var $city="delhi";function xyz(){ echo "Hello ".$this->user." Your city is ".$this->city; }}?>//file name: xyz.php; <?phpfunction __Autoload($x){ include_once("$x.php"); }$obj=new abc;echo $obj->user."<br>";echo " <br>".$obj->xyz();?> output when you brows xyz.php: Raju Hello Raju Your city is delhi here what we see in xyz.php not have any class with the name of abc even i have create here object of class abc, it is automatically called because i am using magic method __autoload($x), $x is variable which is assign by the name of filename abc and in include _once("$x.php"); it become include _once("abc.php"); so this is magic because it represent something like magic. both file should be in same directory. thanks.
  13. Source: http://www.pcguide.com/care/data/virus/bgTypes-c.html Thanks
  14. Thanks to differentiate both thinks bad sector and boot sector and hope that some one sure provide more details but please clarify that if virus erase the boot sector then system should not be working fine after reboot or instantly restart. so what is precaution for this, what i do instantly so my work is not suffering. and window should not corrupted.
  15. Welcome,My one PC is not working fine i want to restore my old file, i made backup in pen drive but how we restore my old file in my system, what is the path to restore the file, i have complete c: drive backup in which i have installing my windows. when i store file by system restore it send error report, there is any way to restore my old file, restore point and backup i think that both are different, there may be problem but i cant resolve it.thanks
  16. Dear all, i am working on my IBM Thinkpad R52, for internet i am using airtel card, and windows XP2 with other software also, what i have problem when i dial for connect to internet, my screen is blank, i reboot the system and system is working fine, after some time again this problem is come my screen is blank. it may be work fine whole day or it may blank after sometime , i solve this again by restarting my laptop but my data each time lost, when without airtel card to internet system is working fine, no any type of error is came, but it is my need that i serf net so i resolve by reboot. but i want exact solution for this what i do, i was also watch my system to hardware engineer he says this system is fine and have no any problem, i say all to my problem he excuse sorry i cant solve i say there is no problem. use as it. but i think there is sure some problem that by my screen is gone to blank when i re forced to connect with net. i am also reinstalled the airtel software which it is used. also i reinstalled windows but problem is same. so please give the way what i exact happened with my system it never hang only blank screen is come. if any body want any log file i can give you but please solve this problem.thanks
  17. hi all,I read so many article related to this topic but overall in confusion what is basic difference in between bad sector and Boot sector in Hard disk , if any sector have bad then what is the first precaution that bad sector should not come. what is the first stage that i find, the bad sector may occurs. somebody says that if virus is running continuously in your system then there is a chance to come bad sector. what is it correct? i think that this is not correct virus could not corrupt the hard disk. (bad Sector or boot sector) what you think that virus have capability to do this task or it is due to any electrical fault happening with your Hard disk. i buy a second hand hard disk to my friends he have query please solve this problem.my hard disk have bad sector or boot sector have we scan found bad sector. but i am confusion what i do for this, any extra utility comes to solve this problem very easy without any extra cost. really it is a big issue in between me and my friends what we do. i bye new one or repair it. any way my extra cost is lost so many things are there. so please help me.thanks
  18. yes money is every thing , so collect it from any way. but my heart is not gives permission to do wrong work. any way i have gone in right direction. i left my real job on last month, now a day i am doing study php+mysql and also designing and developing ecommerce website, so you can say that i am not standing free , i have a job. but after reading your reply i have power to do more work and my energy is recovered. thanks
  19. i my case HOSTING CREDITS are increase as per post but myCent is not update , any one can help me, regard this.why my mycent is not updated and also clear about Credit System V3.0 Online means to increase mycent we login there.
  20. I have some question in mind that need solution so please 1) What is benefit of using header and footer tag in our web page ?2) How we can registered our website on any search engine?3) Did I use animated image without flash in website.? 4) What is the correct way to display web page on center in any browser.? if we use css style ?I have little idea off all question answer but i need specific help so welcome.Thanks
  21. I want to know what configuration changes are required in Local machine to use mail (); function in Localhost to delivered on internet. 1) There are compulsory to install and configure mail server on Localhost to use mail (); ? 2) I have installed WAMP 5 in my localhost machine any change in WAMP configuration file also need to use mail (); ? 3) POP3, MIME, etc also required ? 4) Any more information to complete this task please welcome? 5) Overall my aim is to use mail() in WAMP5 and it should be delivered. OK. I read in the web page that : The mail() function allows you to send emails directly from a script. This function returns TRUE if the email was successfully accepted for delivery, otherwise it returns FALSE. Syntax mail(to,subject,message,headers,parameters) Parameter Description to Required. Specifies the receiver / receivers of the email subject Required. Specifies the subject of the email. Note: This parameter cannot contain any newline characters message Required. Defines the message to be sent. Each line should be separated with a LF (\n). Lines should not exceed 70 characters. Windows note: If a full stop is found on the beginning of a line in the message, it might be removed. To solve this problem, replace the full stop with a double dot: headers Optional. Specifies additional headers, like From, Cc, and Bcc. The additional headers should be separated with a CRLF (\r\n). Note: When sending an email, it must contain a From header. This can be set with this parameter or in the php.ini file. parameters Optional. Specifies an additional parameter to the sendmail program (the one defined in the sendmail_path configuration setting). (i.e. this can be used to set the envelope sender address when using sendmail with the -f sendmail option) Web page also have sample Example: I make changes as where needed but my mail is not delivered, So please anybody could help how to we success in delivering mail from my local WAMP5 to On Internet. Thanks
  22. Hi,I am also using Mozilla Firefox now a days because of due to extra facility with this browser like Tabed, Session, Security, Clear private data on single command "Ctrl+Shift+Del" or with single click. and security issue is also maintain. POPUP Windows due to Virus or else are blocked easly, not start automatically, security level is high. etc. before this i was last used Internet explorer ver6.0, i face so many problem i see that some site also not brows perfectly. but same site if i use on Mozilla Firefox it open well.so Mozilla Firefox is my first choice.
  23. First of all You Should be:1) Think again - Depression is real or is it feeling2) Involve all activity around your. 3) Be yourself dont bother.4) Liston what the others say if while you are with friends.Defination:- Depession is nothing but a part of your mood you can remove it.
  24. I want to know what configuration changes are required in Local machine to use mail (); function in Localhost to delivered on internet. 1) what is necessary to install and configure? 2) I have installed WAMP 5 in my localhost machine.what changes are need in configuration file.? 3) what POP3, MIME, etc is required ? Any more information to complete this task please welcome. Overall i want to use mail() in WAMP5 and it should be delivered.
  25. How to make sure your server can generate imagesThis small article will explain how you create a thumbnail from an image in PHP. Furthermore you learn how to batch process a whole folder of images and create their thumbnails.To create images with PHP you need to have the gd image library installed and activated in your PHP.To make sure if gd is installed on your machine, simply check your php info. Create a file that contains:<?phpinfo()?>and save it as "test.php" on your server. When you open it in a browser you see a colourful table showing all the schematics of your PHP install. In it you have to find something like this: If you know for sure that there is gd on the machine but PHP does not recognise it, it may still be commented in the php.ini.Scan your machine for the php.ini and edit it in a text editor. You will find loads of extensions:;extension=php_fdf.dll;extension=php_filepro.dll;extension=php_gd.dll;extension=php_gettext.dll;extension=php_hyperwave.dlSimply remove the ";" in front of the php_gd and restart your server.;extension=php_fdf.dll;extension=php_filepro.dllextension=php_gd.dll;extension=php_gettext.dll;extension=php_hyperwave.dlThe logic of batch processing thumbnailsYour server is running PHP, gd support is enabled, let's start thinking about the code.To generate thumbnails we do the following:• Scan a folder for JPG and PNG files (gd does not support GIF anymore, because the packing algorithm in GIF is copyrighted).• Take each of these images, and load it.• Resize the image.• Save the image as a thumbnail.The resizing idea is the following:• We assume the thumbnail should be 100 pixels, either wide or high.• We load the original image, and check its dimensions.• If the picture is higher than wide, we set the height of the thumb to 100 pixels.• The width of the thumbnail is the original width multiplied with 100 pixels divided by its height.• Thumbnail height = original width * (100 / original height)• This way we preserve the original aspect ratio.• If the original picture is wider than high, we do the same to the height of the thumbnail.• If they are the same, we simply create a 100x100 pixels image.The PHP functions to usePHP has a whole lot of functions to help us with generating graphics with gd.The ones we need to use here are:• imageCreateFromJPEG() to create a copy to work on of a .jpg image.• imageCreateFromPNG() to create a copy to work on of a .png image.• imageSX() to get the width of the original image.• imageSY() to get the height of the original image.• ImageCreateTrueColor() to create a new truecolour image object.• imageCopyResampled() to resample the image.GD supports truecolour images from version 2.0 onwards, older versions of GD will create JPGs and PNGs with 256 colours and need other functions. I deliberately dropped the support here, as gd2 comes bundled with every newer install of PHP anyways.• imageJPEG() to create a new JPEG image.• imagePNG() to create a new PNG image.• imagedestroy() to delete the old image objects in the memory.Furthermore I created some functions I keep using:• directory() reads a folder and returns all the files that apply to a certain filter.• ditchtn() clears the resulting array from all files starting with a filter you define, like tn_".• createthumb() creates a thumbnail and saves it to the server.directory() and ditchtn() are filesystem and array functions, I will not explain them here, they should be pretty self-explanatory.The main thumbnail generation functioncreatethumb() is the main thumbnail generation function, so let's take a closer look:function createthumb($name,$filename,$new_w,$new_h){ $system=explode('.',$name); if (preg_match('/jpg|jpeg/',$system[1])){ $src_img=imagecreatefromjpeg($name); } if (preg_match('/png/',$system[1])){ $src_img=imagecreatefrompng($name); }createthumb() is called with the following parameters: The name of the original image (if needed with folder name), the name of the thumbnail picture, and the dimensions.These lines get the information if gd is at least version 2.0 and check if the original image is a JPEG or PNG.Accordingly, a new image object is created called src_image. $old_x=imageSX($src_img);$old_y=imageSY($src_img);if ($old_x > $old_y) { $thumb_w=$new_w; $thumb_h=$old_y*($new_h/$old_x);}if ($old_x < $old_y) { $thumb_w=$old_x*($new_w/$old_y); $thumb_h=$new_h;}if ($old_x == $old_y) { $thumb_w=$new_w; $thumb_h=$new_h;}These lines get the dimensions of the original image by using imageSX() and imageSY(), and calculate the dimensions of the thumbnail accordingly, keeping the correct aspect ratio. The desired dimensions are stored in thumb_w and thumb_h. $dst_img=ImageCreateTrueColor($thumb_w,$thumb_h); imagecopyresampled($dst_img,$src_img,0,0,0,0,$thumb_w,$thumb_h,$old_x,$old_y); These lines create the image as a true colour version using ImageCreateTrueColor() and resize and copy the original image into the new thumbnail image, on the top left position. if (preg_match("/png/",$system[1])){ imagepng($dst_img,$filename); } else { imagejpeg($dst_img,$filename); }imagedestroy($dst_img); imagedestroy($src_img); }These lines check the file system extension of the original image and create the thumbnail accordingly. The thumbnail gets saved onto the server (by adding a filename to imagejpeg() or imagepng() function) and the two image objects get destroyed to free the memory.How to use createthumb()Let's say you have an original picture called apple.jpg in a folder pics and you want to generate the thumbnail in the folder thumbs as tn_apple.jpg 100x100 pixels big.You can do this by calling this function with the following parameters:createthumb('pics/apple.jpg','thumbs/tn_apple.jpg',100,100);To batch process all the pictures in the folder pics and generate their thumbnails in the folder thumbs you do the following:$pics=directory('pics','jpg,JPG,JPEG,jpeg,png,PNG');$pics=ditchtn($pics,'tn_');if ($pics[0]!=''){ foreach ($pics as $p) { createthumb('pics/'.$p,'thumbs/tn_'.$p,100,100); }}You grab all the pictures from the pics folder via directory() and a filter for images.Then you delete all the thumbnails by using ditchtn() and make sure that the resulting array is not empty.The second parameter in ditchtn() must match the name you give your thumbnails, this is done to prevent thumbnails being generated from thumbnails.You then loop over all images and generate the thumbnail with the desired dimensions and names.Caveats and downloadGenerating thumbnails with PHP is pretty handy and saves you a lot of time pushing files onto your server via FTP. It also makes it easier to keep a image gallery up to date.Using the functions introduced here it is no problem to scan a folder for new images and create the thumbnails when new images were uploaded.PHP with gd can be very slow at times though, especially when the machine is not too fast and the resample() function is used. Some servers might stop telling you the maximum time of script execution has been not enough. You can change this in your php.ini:max_execution_time = 320 ; Maximum execution time of each script, in secondsNow, try to generate some thumbnails on your own server by playing with the thumbnail generator, a script that has all the functions described above included.
×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.