Not sure exactly what you asking for, maybe this:
SELECT d.* FROM ( wp_rg_lead_details d
JOIN wp_rg_lead l ON (d.lead_id = l.id))
WHERE l.source_url = '$source_url'
AND d.value like '%$value%';
assuming there is a column id
in your table wp_rg_lead