Removing Characters...

free web hosting
Open Discussion > CONTRIBUTE > Computers > Programming Languages > C/C++ Programming

Removing Characters...

kvarnerexpress
From the environment variables, i get the domain of the referring site using SERVER_NAME. The includes www. and i have to remove that. I dont believe there is a variable in the environment that contains only the domain.

So I would need to replace each character in the char* string by "" until i hit a '.' then replace the dot with "" and get the remaining string. Here is the catch. I can't include big headers because i need the file to stay really small around 20-30kb. So ideally, would need to use functions in stdlib.h stdio.h or string.h to get this done.

Thanks in advance

Reply

kvkv
Here is an easy solution for your problem.

CODE

{servenv++;}while((*servenv)!='.'); //increment char* till next character to '.'
//use servenv here. it points to next character of the first '.'


Reply



Got an Opinion! Express your Views! (no registration):-
Add your Reply/ Opinion/ Views/ Comments/ Suggestion/ Questions/ Queries etc.
Posts with decent grammar & English will be accepted and please refrain from profanities.
For asking a Question, We recommend you to sign-up (for free) so that you can track the topic easily.

Nature of your Post*: Opinion/ Reply/ Comments
Question/Query
Feedback to us.
       
Name   Email
Title/Question*

(Maximum characters: 10,000)
You have characters left.

Similar Topics

Keywords : removing, characters

  1. Things To Know About Dreams
    Symbols, dream phonomenons, symbolic characters, kinds of dreams, colo (1)
  2. Special Characters In The Web Address
    help nedded for using special characters in the path and then usin the (0)
    hi i am new to htaccess. i was trying to write a rewrite rule in the htaccess for utilizing
    special characters but was unsuccessful...... cud pl anyone help me out working out the same.....
    here's it i a trying to rewrite the following url CODE
    http://www.example.com/*service:forums|passive:true as CODE
    http://www.example.com/index.php?service:forums|passive:true the code i added in
    htaccess was...... CODE Options +FollowSymlinks RewriteEngine on RewriteRule
    ^\*(.+)$ index.php?$1 [nc] ....
  3. Favorite Video Games Characters
    From the old NES to the new Xbox360 and PS3 (1)
    I remember playing the old Zelda games on the NES system and Link was little more then a 8-bit dot
    with big ears and a green hat. It really didnt have much of a story plot to it and the characters
    weren't really in depth, but it was still fun to play. As the gaming world advanced, graphics
    got better and game system held more memory. This gave me a new respect for gaming because Link had
    a personally, life like and believable. Metal gear was also one of my favorites. In the old nes game
    I really didn't care if I die, it was like "ok whatever Im dead" but in the P....
  4. Converting Textarea Return Characters To <br />
    (9)
    Hi guys, I have set up a form with a textarea. If I have text on multiple lines such as: CODE
    here is some content here is some more content then when I print it out as html it will be
    returned on one line like so: CODE here is some contenthere is some more content When i
    look at the content in the database it looks just like the original way i entered it (contains the
    multiple lines). Is there a function in php so that when i spit it out in html it retains the
    multiple line format? Thanks in advance. ....
  5. Unable To Renew Ip Address Or Connect To Internet After Broadband Software Uninstall
    issues after removing DSL software (6)
    How many of you experienced this? QUOTE Unable to renew IP address Unable to start RPC service
    You invite a broadband service, i.e. Verizon DSL, and they provide you with an installation disk.
    You gladly use it but later you add LAN to your home and decide to add a router. You follow the
    manufacturer's instruction and set up your home network. But this is strange... the computer you
    were able to connect to the internet just before a home network is now cannot connect to the
    internet. And according to the router manual you installed the program correctly but ....
  6. A Small Html Problem
    How to display foreign characters correctly when designing a site. (4)
    I was wondering how I could solve a small problem. I was told that some people see accented and
    umlauted letters (such as " é " and " ë ") as question marks (" ? ") on my website. I come across
    the same thing sometimes when looking at websites which use non-English characters. Funnily enough,
    the other day, I looked at a site and the apostrophy ( ' ) was also shown as a question mark.
    That is a very common character usually, I would think. I thought it had something to do with the
    character encoding settings, and let me also mention I use Mozilla Firefox as my brows....
  7. Special Case Characters.
    Inclusion in the FAQ. (0)
    I searched the FAQ's and the forum but didn't find anything that may answer this query so I
    am posting it here so other having this problem may benefit from it here. When I was creating the
    account I found out that using special case character in the passwords was not allowed when creating
    the hosting account. I didn't use any of the special case character in my hosting account but
    the system was generating invalid username and password for the forum too. Since special case
    characters and Alpha-numeric boats high security in passwords I use them on the forum....
  8. Validation Script - Detecting Illegal Characters
    preg_match to find illegal characters (0)
    I'm trying to validate a user's desired username for a registration page. I want to detect
    any illegal characters being used for a username. So far i have managed to include most execpt the
    '\', the '\' is used for escape and treating the preceding characters
    literally. I try to do '\\' but i get an error because it execects another
    character. CODE $ck_result = "Default"; $pattern =
    "/[!|@|#|$|%|^|&|*|(|)|_|\-|=|+|\||,|.|\/|;|:|\'
    ;|\"|&#....
  9. Site Displays Weird Characters Instead Of Site
    (6)
    Okay so I have a website at www.clanxs.qupis.com or at www.xsnipaz.tk but whenever I go there all i
    get is a wierd box and an arrow... Some people can see the actual site and some just see the weird
    characters... Ill upload an image later (at the moement im on a dialup connection...) I was
    wondering if this was a qupis error message or if anyone else experiences this problem and how you
    cna fix it.... any help is appreciated AGEN....
  10. Testing čćžđš Utf-8 Characters :)
    Testing čćžđš UTF-8 characters :) (4)
    Just a char-test /biggrin.gif" style="vertical-align:middle" emoid=":D" border="0"
    alt="biggrin.gif" /> čćžđš....
  11. Problem Removing Folder On Ftp
    (6)
    hello i've been trying to remove a folder on my ftp location here at trap17 but it doesn't
    seem to do anything at all if an admin or anyone else who has the capabilities can remove it,
    i'd be gratefull the foldername is XD-RedZone....
  12. Removing My Qupis Account And Restoring Hosting By Trap17.com Addless Hosting
    Please Help Me Out Here (5)
    Hey, I have decided Qupis is not for me, but I am having trouble getting rid of my hosting acocunt
    with them and reverting back to the old trap17.com credit-based free addless hosting. I have reset
    my nameservers to ns1 and ns2 .trap17.com and logged into my cpanel (I left over 24 hours for this
    to change) but my cpanel still says hosting package is qupis, and sure enough the ads are still
    present. How can I stop this happening please? I would like to delete my qupis account (how do
    this?) accountname="jimmy" and any other information required to set up original setup&#....
  13. Firefox 2.x.x Removing Tab Scroller
    If Tab scroller is anoying you like it did me, simply remove it... (3)
    You can remove Firefox 2.0 or higher tab scroller, an invention annoying like linux distros simple
    as walking few miles on your hands /ohmy.gif" style="vertical-align:middle" emoid=":o" border="0"
    alt="ohmy.gif" /> . Just a joke, it's much much simpler. Three steps proces 1. open your
    firefox and type about:config in adress bar (the place where u usually type
    http://trap17.com/forums) , without that http thingy 2. find option browser.tabs.tabMinWidth and
    change the value to 0 -- 3. restart your lovely firefox, and start it again.. Enjoy your
    No-Tab-Scrolling su....
  14. Vb6 And Unicode
    Problems displaying unicode characters with VB6 (0)
    Everyone knows this, but I thought I would repeat it, and offer my solution , no, not solution, a
    workaround, for this problem... As most of you know, VB6 is built internaly with unicode support,
    but all it's custom controls, are only ANSI compliant, meaning you will get a series of
    ???'s when inserting unicode characters, from, say, MySQL database... There are tons of
    solutions for this, from using API to create a textBox that supports unicode, to using MS Forms 2.0,
    buying custom ActiveX that has support for unicode, and ofcorse, migrating to .Net... Well, a....
  15. Boston Hoax - Marketing Stunt Gone Wrong
    Cartoon Characters labeled as terrorism (3)
    Well on Feb 1,2007 there was a Boston scare over a group of signs of the characters on Aqua Teen
    Hunger Force Ignignokt and Err if you dont know who they are i suggest you look it up. Now in some
    parts of the subway areas of boston neon signs of Ignignokt and Err doing what they are famous
    giving the bird was thought to be a threat of terrorism seeing that a majority of these signs was
    all over that seem a bit suspicious so the Boston police did what they had to do and took action by
    doing this they shut down the roads and everything was at a stand still remember all t....
  16. Php Escaped Control Characters And Windows
    they aren't working for me. (3)
    In php coding, when you escape certain characters, they have an impact on the output of an
    echo'd or printed string. ie "\r\n\t" should give you a new line and a tab before
    outputting the content for a line of printing. They vary by OS, I know, but I have tried all the
    variations I can think of and can't seem to control output using them. Believe me, I have tried
    multiple variations and nothing works for me. I have checked the php.ini file for settings but I
    can't find where you can modify them. So the question is : Where do i look to conf....
  17. Sonic Style Characters/drawing Requests
    (2)
    Can anybody tell me some websites that have to get some sonic style charries or if anybody is any
    good at drawing their own charcaters like this one for instance... ....
  18. Character Profiles (because I'm Bored And Thinking About Them)
    Characters for a Spy story I'm trying to develop (0)
    Well, there actually IS a bit of a reason for all this... It kinda elaborates on what I'm
    discussing over here . And I would love some opinions on what I've got so far. The setting is
    mostly Spy Genre, James Bond kinda stuff, although this group focuses more in intel gathering rather
    than search-and-kill. The twist is the addition of psychic abilities, refered to as "Potential" -
    the idea being that, theoretically, everyone should be able to do this things, and these people have
    "reached" or are "finding" their Potential. Most potentials in G3 are enhanced or d....
  19. Mega64
    Game characters come alive :P (4)
    Mega64 Not sure how many of you know of this, but it's a funny website. They take famous
    games, and mimick them in real life. In one, he goes around in a Metal Gear Solid suit and runs
    around a supermarket /laugh.gif" style="vertical-align:middle" emoid=":lol:" border="0"
    alt="laugh.gif" /> Give it a look if you're bored /tongue.gif" style="vertical-align:middle"
    emoid=":P" border="0" alt="tongue.gif" />....
  20. DNS Hijack SearchAtHand.com Browser Result Removal
    this is a browser hijack and method of removing (6)
    Recently, I don't know when, I realized that my browser was opening some weird pages. It would
    either open to what it seemed to be a valid webpage but it always looked the same. But the contents
    will be text only but always with adult related links... so I was curious but never paid any
    attention since these pages were coming up only when I mistyped an URL address. But the pages
    popped up were always the same and it got me curious. So I started to click on refersh and see how
    far it will lead. At the end, it led to a site called "SearchAtHand.com" After few minutes ....
  21. Removing Warts Methods
    is freezing the best way? (10)
    Warts seem to run in my family. I just had one froze on my foot today. I have had many on my hand
    too. It's not really that they hurt, but just knowing they are there make you uncomfortable. Do
    any of you guys have warts? Is freezing the best way to get them off? Freezing isn't that
    paniful, but is there an easier way. I heard something about putting duct tape on them.....
  22. Minimum Characters In Posts
    (12)
    To cut down on spam at IPB Gaming I installed a nice little mod that forces a member to post a
    certain amount of characters. Link ---> http://mods.invisionize.com/db/index.php/f/5890
    ...Will get rid of short, pointless, stupid, and ignificant and annoying posts that can sometimes
    plague a forum. Take a look if you haven't already.......
  23. Integerate Your Site With Talking Characters - Ms Agents
    (7)
    Hello All Have You ever seen the above MS Agents in any of the websites ? They Demonstrate
    things,Explain,Greet your visitor, Give Information about the user and above all they give a pretty
    cool cool to your website! Want them on your site? This tutorial will explain on how to
    Integerate MS Agents in your website! For those who cannot understand what I am talking about
    or want to see a sample check them on sample page! ->->->
    http://www.technik.co.in/docs/agent_sample.htm This tutorial may feel every long but beleieve me I
    have made it easy as much as....
  24. Converting Characters In A Variable To Individual Values In An Array
    turning variables into arrays (2)
    Say I have a variable such as $nav_item and it had to contents Home . IE: CODE
    $nav_item = 'Home'; How would I make so that $nav_item was an array and
    had the following contents? CODE $nav_item = array ('h', 'o',
    'm', 'e'); With the case changing (ie H would become h and U
    would become u ) EDIT: Okay found out that I could change the case with
    array_change_key_case ($nav_item, CASE_LOWER); ....
  25. Final Fantasy 9 Renaming Characters
    Anyone know how to rename your charcters? (8)
    Does anyone know how to rename your characters in Final Fanatsy 9? I'm up to disc 2 start and i
    named my charcters and it's getting confusing a little bit, lol, and i want to know if i can
    rename them or if i should just start again (even though this is the 5th time i've played ff9 i
    should know this by now). Thanks. Rock on Final Fantasy....
  26. Manual Virus Removing And Security.
    (0)
    Talking about manual removals of viruses I thought I better be a pioneer of this by sharing my
    knowledge about a virus. I would like to tell the effects and manual removing technique of a very
    common and irritating virus, that is HTML Redoff. First I would like to discuss its effects, HTML
    Redoff virus infects kernel32.dll file which is installed in your “WINDOWS\SYSTEM” directory in
    case you have Windows 98 and “WINDOWS\SYSTEM32” directory in case you have Windows XP and all
    the .htm, .html, folder.htt and desktop.ini files on your PC thus it slows down your....
  27. Who's Your All Time Favourite Hidden Characters?
    Street Fighter, Mortal Kombat, X-Men Games. (3)
    You know how you go through certain games and you play at the hardest level or you beat a game
    without ever losing around because you're that darn good. And usually you are rewarded by
    fighting a secret character. These are characters that are above the regular characters you fight
    against. Hidden Characters almost always have that unfair advantage over every single little thing
    that you do. And if you somehow manage to beat this hidden Character he/she might become playable
    using a code or not. Hidden characters --- There's always a catch for you to actually u....
  28. Isolating Integers From Characters?
    (4)
    Hi there people! I'm new here, so if this post conflicts with any of the laws of this forum
    for any reason, I apologize in advance. I'm trying to write a function that reads from the user
    a set of integers separated by ',' (commas), but I'm having difficulty isolating the
    integers from the characters. I'm not sure if I should do it using a "for" or "while" loop,...
    So if the input is something like: {100,20,50} I should be able to store the integers 100 20 50
    Anybody got any idea how to do that?? I would really appreciate the help!! ....
  29. Title Attribute
    and HTML entities for special characters (5)
    Hi, I've had this trouble for a time now, I use dreamweaver to develop the sites I work with,
    and dw always writes the code for me (not that I don't know anything about xhtml, in fact i
    consider myself and advanced user of xhtml, but I know that its faster to use dreamweaver to code
    than write it down from scratch, and I can still fix the little issues that dw generates into the
    code). But the fact is that I work with websites that need the content in spanish, so I use html
    entities to declare special characters such á é í ó ú or ñ, all of which always behave we....
  30. Super Smash Bros Melee
    the best GCN game?+fav characters (39)
    so many people love SSBM. people buy the GCN just for this game! here we shall discuss random
    stuff about it's greatness! my best characters:(ordered) 1.Falco 2.Luigi 3.Peach 4.Roy
    5.Young Link/ Link (same) this game in my opinion is the best fighting game ever. it takes skill
    and a noob cant just walk up and button mash and win against an advanced player like in other
    fighting games. even the cheepest tactics can be countered by a skilled player. according to many
    tiers(best character lists) there are the top characters: 1.Sheik(not zelda) 2. Fox 3. Marth....

    1. Looking for removing, characters

*RANDOM STUFF*





*SIMILAR VIDEOS*
Searching Video's for removing, characters

*MORE FROM TRAP17.COM*
Similar
Things To Know About Dreams - Symbols, dream phonomenons, symbolic characters, kinds of dreams, colo
Special Characters In The Web Address - help nedded for using special characters in the path and then usin the
Favorite Video Games Characters - From the old NES to the new Xbox360 and PS3
Converting Textarea Return Characters To <br />
Unable To Renew Ip Address Or Connect To Internet After Broadband Software Uninstall - issues after removing DSL software
A Small Html Problem - How to display foreign characters correctly when designing a site.
Special Case Characters. - Inclusion in the FAQ.
Validation Script - Detecting Illegal Characters - preg_match to find illegal characters
Site Displays Weird Characters Instead Of Site
Testing čćžđš Utf-8 Characters :) - Testing čćžđš UTF-8 characters :)
Problem Removing Folder On Ftp
Removing My Qupis Account And Restoring Hosting By Trap17.com Addless Hosting - Please Help Me Out Here
Firefox 2.x.x Removing Tab Scroller - If Tab scroller is anoying you like it did me, simply remove it...
Vb6 And Unicode - Problems displaying unicode characters with VB6
Boston Hoax - Marketing Stunt Gone Wrong - Cartoon Characters labeled as terrorism
Php Escaped Control Characters And Windows - they aren't working for me.
Sonic Style Characters/drawing Requests
Character Profiles (because I'm Bored And Thinking About Them) - Characters for a Spy story I'm trying to develop
Mega64 - Game characters come alive :P
DNS Hijack SearchAtHand.com Browser Result Removal - this is a browser hijack and method of removing
Removing Warts Methods - is freezing the best way?
Minimum Characters In Posts
Integerate Your Site With Talking Characters - Ms Agents
Converting Characters In A Variable To Individual Values In An Array - turning variables into arrays
Final Fantasy 9 Renaming Characters - Anyone know how to rename your charcters?
Manual Virus Removing And Security.
Who's Your All Time Favourite Hidden Characters? - Street Fighter, Mortal Kombat, X-Men Games.
Isolating Integers From Characters?
Title Attribute - and HTML entities for special characters
Super Smash Bros Melee - the best GCN game?+fav characters
advertisement



Removing Characters...



 

 

 

 

ADD REPLY / Got an Opinion! a humble request :-) RAPID SEARCH! Free Hosting [X]
Express your Opinions, Thoughts or Contribute your information that might help someone here.
Ask your Doubts & Queries to get answers.. "Together, We enlight each other!"
Register FREE for AD-FREE forum, Create your own topics, Ask Questions, track topics, setup subscriptions & notifications and Get a Free Website w/ Email and FTP.
500MB Space *No Ads*, CPanel, FTP, PHP, MySQL, EMails - 100% FREE