twittoris Posted September 6, 2010 Share Posted September 6, 2010 I am trying to insert a variable into this post string: curl_setopt ($ch, CURLOPT_POSTFIELDS, 'p_entity_name=The+Company+Name+LLC&p_name_type=A&p_search_type=BEGINS'); I want to replace company name with $name like: curl_setopt ($ch, CURLOPT_POSTFIELDS, 'p_entity_name='+ $name + 'p_name_type=A&p_search_type=BEGINS'); Quote Link to comment Share on other sites More sharing options...
mraza Posted September 6, 2010 Share Posted September 6, 2010 ($ch, CURLOPT_POSTFIELDS, 'p_entity_name='. $name .'&p_name_type=A&p_search_type=BEGINS'); u need to use concatenation operator Quote Link to comment Share on other sites More sharing options...
twittoris Posted September 6, 2010 Author Share Posted September 6, 2010 Thanks I actually just tried that. Now I need to format the string to convert special characters like S&H Equities LLC what command do i use for that? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.