Treated to a hero's welcome, Turkey's prime minister met Syrian refugees Sunday for the first time since his country opened its doors to tens of thousands of Syrians fleeing their government's crackdown on a popular uprising.

Recep Tayyip Erdogan vowed to defend the rights of the Syrian people, saying they were close to achieving success. He was greeted by joyous Syrians at the largest refugee camp near the border.

Erdogan has urged Syrian President Bashar Assad to quit and has encouraged the Syrian opposition to unify and present a credible political alternative. His visit to the border region comes before a parliamentary election in neighboring Syria, where the government's heavy-handed reaction to civilian protests more than a year ago is threatening to spawn a full-scale militarized conflict.

"Bashar is losing blood day by day," Erdogan said in an address to thousands of joyous Syrians at the camp near the town of Kilis. "Sooner or later, those who have oppressed our Syrian brothers will be accounted for before their nation. Your victory is close."

Many refugees used their mobile phones to film or took pictures of Erdogan, who addressed the crowd from the top of a bus as snipers stood on rooftops. The camp, housing more than 9,500 refugees, came under cross border fire by Syrian forces last month in an incident that left two refugees dead.

It is the most organized and well-equipped camp: refugees stay in white temporary housing units instead of tents as in nine other camps along the border. It looks like a small town with wide streets, soup kitchens, a health clinic and even a makeshift barber shop. A mosque with a minaret is located just outside the camp.

Erdogan assured the refugees that they are Turkey's guests until they decide to return home in safety, as the refugees burst into applause. Erdogan thanked them with a few words in Arabic.

Turkey hosts around 23,000 Syrian refugees who have fled Assad's crackdown, which is estimated to have left more than 9,000 people dead.

Before visiting the camp on Sunday, Erdogan said: "Until the will of the Syrian people comes to power, we will continue to defend our brothers rights there and welcome our brothers who come here with open arms. Inshallah (with God's will) these gloomy days will be overcome."

The Syrian regime has portrayed Monday's vote as a sign of its willingness to carry out reforms, but Syrian opposition leaders and activists are skeptical. A U.N.-brokered truce last month has failed to halt the violence in Syria.

Monday's election comes more than three weeks after an April 12 cease-fire aimed at paving the way for political talks between Assad and those trying to bring him down.

The truce, brokered by special envoy Kofi Annan, has failed to take hold, though U.N. observers say it's helped bring down the level of violence. Regime forces continue to attack opposition strongholds and carry out arrests, while refusing to withdraw troops and tanks from streets, as required by the Annan plan. Rebel fighters continue to target soldiers in shootings and bombings.

Turkey, NATO's biggest Muslim member, does not want to be seen as a bystander to atrocities on its doorstep, but it is also careful not to be dragged into the conflict. Turkey has been relentlessly calling for international consensus on Syria, which simply does not exist.