I had been working on module and well aware of hook_menu for passing url arguments to call back. For instance:
$items['webtv/block/%/playlist/edit/%'] = array(
...
'page callback' => 'drupal_get_form',
'page arguments' => array('webtv_playlist_form', 5, 2),
...
);
and callback as
function webtv_playlist_form($form_state, $fifth_arg, $second_arg){
...
}
Beside that arg() function is another utility to get url arguments by their positions.
$second_arg = arg(2);
$fifth_arg = arg(5);
When I enable locale module to make web as multilingual, URLs are classified with prefix as language symbol. Example:
en/webtv/block/%/playlist/edit/%
OR
nl/webtv/block/%/playlist/edit/%
This thing displaces the logical placement of arguments to right, now the correct placement of arguments (according to example) is:
$second_arg = arg(3);
$fifth_arg = arg(6);
How to set-up module independent of such argument placement issues?