The $FeCl_3$ acts as a Lewis acid catalyst to generate the electrophile $Cl^+$. The methoxy group (-OCH3) is an ortho/para directing group. The ester group is a meta directing group. The methoxy group is a stronger activating group than the ester group is
Show more…